Categories > Coding > PHP >

[RELEASE] API For Creating Hastebin and Linkvertise Links

Murz

PixelPenguin

Posts: 240

Threads: 20

Joined: Jul, 2021

Reputation: 29

Posted

Hello, I was bored and needed a project idea, I created a API for creating Hastebin and Linkvertise links in PHP.

 

This was inspired from a post made by AlternateD.

 

Documentation: https://eurythmical-salvage.000webhostapp.com/documentation

 

Hopefully the documentation isn't confusing, I am not the best explainer, if you need another explanation just let me know and I'll try to help!

 

For the linkvertise part, I did get the main concept from this guy on github, here is the repo. It was made in javascript, I converted it over to PHP.

 

Though I do not recommend using the API for linkvertise if you are looking for security as bypassing it is really easy since it uses Base64 encryption.

 

The following is the source code of the project;

https://eurythmical-salvage.000webhostapp.com/source

https://cdn.discordapp.com/attachments/1066565161135116318/1067246964338593832/carbon.png

  • 0

 

Ty for rep: Swiney, Byoke, Lion, Locust, Waves, Weeb, Nickk, darkn, Atari, CubeFaces, Lux14, Rice, Delta, Syraxes, Aeon, Jordan, Pluto, and Hiroku!

P.S, I like cats better too!

Posts: 2013

Threads: 198

Joined: Apr, 2021

Reputation: 16

Replied

As you said, very insecure, but I'm glad seeing someone using PHP.

  • 0

Random quote here...

Alternate

stop take my rice

vip

Posts: 712

Threads: 113

Joined: Mar, 2022

Reputation: 40

Replied

I'm glad I could be inspiration! Good job on this!

  • 0

we are dead

Murz

PixelPenguin

Posts: 240

Threads: 20

Joined: Jul, 2021

Reputation: 29

Replied

@VoidableMethod yea, sadly the linkvertise api isn't the best for this type of a situation. However, the hastebin works amazingly! I'm glad you found this project interesting :)

  • 0

Added

@Alternate Thank you very much, your project was very neat and I wanted to create a API for it hoping you didn't mind :)

  • 0

Added

@bennytrt,

 

no need to change it, use it if you want to! I released it for all to use, :)

  • 0

 

Ty for rep: Swiney, Byoke, Lion, Locust, Waves, Weeb, Nickk, darkn, Atari, CubeFaces, Lux14, Rice, Delta, Syraxes, Aeon, Jordan, Pluto, and Hiroku!

P.S, I like cats better too!

Posts: 34

Threads: 8

Joined: Jul, 2022

Reputation: 10

Replied

you can break some linkvertise bypassers by doing this:

 

<?php

$type = $_GET["type"];
$id = $_GET["id"];
$content = $_GET["content"];

function createHastebin($data)
{
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, "https://hastebin.com/documents");
    curl_setopt($ch, CURLOPT_POST, true);
    curl_setopt($ch, CURLOPT_POSTFIELDS, array('data' => $data));
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    $resp = curl_exec($ch);
    
    echo "https://hastebin.com/raw/".json_decode($resp, true)["key"];
}

function createLinkvertise($link, $uid)
{
    $math = rand() * 1000;
    $linkvertiseLink = "https://link-to.net/".$uid."/".$math."/dynamic?redirect=".base64_encode("OAWIDJwoiJDwaoiJDWOijdwaoiD")."&r=".base64_encode($link)."&redir=".base64_encode("https://notas.it/e");
    
    echo $linkvertiseLink;
}

if ($type == "hastebin" && $content != "") { createHastebin($content); }
else if ($type == "linkvertise" && $content != "" && $id != "") { createLinkvertise($content, $id); }
else { echo "One of the parameters is invalid."; }

?>

 

this should work because some of them don't parse args correctly.

  • 0

veh_handler and seh_handler disliker

<p>enis</p>

Murz

PixelPenguin

Posts: 240

Threads: 20

Joined: Jul, 2021

Reputation: 29

Replied

@Verbum, interesting. Nice protection methods, :)

  • 0

 

Ty for rep: Swiney, Byoke, Lion, Locust, Waves, Weeb, Nickk, darkn, Atari, CubeFaces, Lux14, Rice, Delta, Syraxes, Aeon, Jordan, Pluto, and Hiroku!

P.S, I like cats better too!

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )