Skip to content

Instantly share code, notes, and snippets.

@DiscordLinuxBot
Created April 10, 2021 23:32
Show Gist options
  • Save DiscordLinuxBot/d75b16a9d73b399506fb042ec81cb56c to your computer and use it in GitHub Desktop.
Save DiscordLinuxBot/d75b16a9d73b399506fb042ec81cb56c to your computer and use it in GitHub Desktop.
sybash.bbtag
{switch;{commandname};
["sybash","bash","_autoresponse_0","_autoresponse_1"];
{jset;~head;method;POST;c}
{commit}
{jset;~body;stdin;{base64encode;{exec;bashrc}};c}
{jset;~body;program;base64 -d - | tr -d '\r' > ./bashrc{semi}source ./bashrc{semi}{args};c}
{commit}
{set;!~json;{jget;{request;http://syretia.cf/bash?key={exec;syretia.cf};{get;~head};{get;~body}};body}}
{fallback;timeout}
{if;{math;+;{length;{jget;~json;stderr}};{length;{jget;~json;stdout}}};>=;1700;
{set;!~sburl;{exec;termbin;{jget;~json;stdout}}}
{embed;{embedbuild;
author.icon_url:{useravatar};
author.name:{usernick};
color:{exec;usrclr;{userid}};
title:**Link to output**;
url:{get;~sburl};
description:*First 800 characters of output:*{newline}{repeat;`;3}{newline}{regexreplace;{lower;{usernick}}@{lower;{guildname}};/\s/g;_}:~>{space}{replace;{jget;~json;program};base64 -d - | tr -d '\r' > ./bashrc{semi}source ./bashrc{semi};}{newline}{substring;{if;{jget;~json;stderr};!=;{null};{jget;~json;stderr}{newline}}{if;{jget;~json;exit};!=;{null};{jget;~json;stdout};{get;~json}};0;800}{newline}[...]{newline}{newline}Exit code: {jget;~json;exit} | Time: {jget;~json;time}{newline}{repeat;`;3}{newline}*{get;~sburl}*}};
{repeat;`;3}
{regexreplace;{lower;{usernick}}@{lower;{guildname}};/\s/g;_}:~>{space}{replace;{jget;~json;program};base64 -d - | tr -d '\r' > ./bashrc{semi}source ./bashrc{semi};}
{if;{jget;~json;stderr};!=;{null};{jget;~json;stderr}{newline}}{if;{jget;~json;exit};!=;{null};{jget;~json;stdout};{get;~json}}{newline}
Exit code: {jget;~json;exit} | Time: {jget;~json;time}{newline}{repeat;`;3}};
{jset;~head;method;POST;c}
{commit}
{if;{get;~stdin};!=;{null};{jset;~body;stdin;{get;~stdin};c}}
{jset;~body;program;{args};c}
{commit}
{set;!~sybash;{jget;{request;http://syretia.cf/bash?key={exec;syretia.cf};{get;~head};{get;~body}};body}}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment