Skip to content

Instantly share code, notes, and snippets.

@Aebian
Created November 14, 2021 16:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Aebian/bac274f0101488aa20c9bf85d9daa993 to your computer and use it in GitHub Desktop.
Save Aebian/bac274f0101488aa20c9bf85d9daa993 to your computer and use it in GitHub Desktop.
<?php
/*
author: @Aebian
description: WakeOnLan of computers
returns: started computer
created: 2021-11-13
*/
$userName = $_GET["u"];
$codeSection = $_GET["c"];
$deviceName = $_GET["device"];
if ($userName == "someName" && $codeSection == 123456789)
{
switch ($deviceName)
{
case "computerName":
$itsAebian_output = shell_exec('wakeonlan <M:A:C>');
echo "Sent Wake to computerName";
break;
default:
echo "No device specified.";
}
} else
{
echo "Authentication not successful.";
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment