added more images, script tidy, cron script added
1 parent 9f12d55 commit 1d521228d61e70a943edbf117f2e605cfe28da7b
root authored on 30 Jul 2019
Showing 28 changed files
View
Img/0xRoM.png 0 → 100644
View
Img/debian.png 0 → 100644
View
Img/dick.png 0 → 100644
View
Img/doom.png 0 → 100644
View
Img/doom_guy.png 0 → 100644
View
Img/eff.png 0 → 100644
View
Img/eggplant.png 0 → 100644
View
Img/guy_fawkes.png 0 → 100644
View
Img/heart.png 0 → 100644
View
Img/heartbleed.png 0 → 100644
View
Img/kali.png 0 → 100644
View
Img/krack.png 0 → 100644
View
Img/matrix.png 0 → 100644
View
Img/metasploit.png 0 → 100644
View
Img/mr_robot.png 0 → 100644
View
Img/oddlaw.png 0 → 100644
View
Img/oshw.png 0 → 100644
View
Img/pwnStar.png 0 → 100644
View
Img/shellshock.png 0 → 100644
View
Img/snubs.png 0 → 100644
View
Img/tits.png 0 → 100644
View
Img/tux.png 0 → 100644
View
Img/wally.png 0 → 100644
View
Img/woof.png 0 → 100644
View
13
cron.php 0 → 100644
<?php
$mainScript = "/opt/DrawOnHisBadge/index.php";
$imagesDir = "/opt/DrawOnHisBadge/Img/";
 
echo "[i] cron - DrawOnHisBadge Random Image\n";
// pick random image
$images = glob($imagesDir . '*.png', GLOB_BRACE);
$randomImage = $images[array_rand($images)]; // See comments
echo "[i] image: $randomImage\n";
 
system("php5 $mainScript $randomImage");
 
?>
View
drew_goatse.jpg 0 → 100644
View
drew_pedobear.jpg 0 → 100644
View
12
index.php
#!/usr/bin/php
<?php
//error_reporting(0);
 
$host = '52.43.252.153'; // websocket server
$port = 9001;
$local = "http://localhost"; // origin header
echo "[!] Please choose an image\n";
exit(0);
}else{
$imgStats = list($width, $height, $type, $attr) = getimagesize($filename);
echo "[i] Height: $imgStats[1]\n";
echo "[i] Width: $imgStats[0]\n";
echo "[?] checking dimensions\n";
if($imgStats[0] <> 64 || $imgStats[1] <> 32)
die("[-] Image must be 64px Wide and 32px high");
 
$im = imagecreatefrompng($filename);
$arrC = array();
//calculate percentage
$count++;
$percent = round(($count / 64) * 100, 2);
echo "[+] complete: $percent% \r";
echo "[+] complete: $percent% \r"; // extra spaces are important sytalisticly
 
for($y = 0; $y <= $imgStats[1]-1; $y++){
$rgb = imagecolorat($im, $x, $y);
$newcol = color565($im, $rgb);
$g = (($green >> 2) & 0x3f) << 5;
$r = (($red >> 3) & 0x1f) << 11;
return "0x". strtoupper(dechex($r | $g | $b));
}
 
/***
* functions below are for websocket interaction
*/
 
// hibi10 decoding of data
function hybi10Decode($data)
{
}
 
return $decodedData;
}
 
// hibi10 encoding of data
function hybi10Encode($payload, $type = 'text', $masked = true) {
$frameHead = array();
$frame = '';
Buy Me A Coffee