diff --git a/docroot/index.php b/docroot/index.php new file mode 100755 index 0000000..e71e327 --- /dev/null +++ b/docroot/index.php @@ -0,0 +1,46 @@ +cmd)) { + print('{"result":"ERROR","errorCode":"0xDEADBEEF","errorString":"You Dumb Mother Fucker"}'); + exit(0); +} + +switch ($pData->cmd) { + case "register": + if ($pData->username != "test@zirror.com") { + $rData['result'] = 'GRANTED'; + $rData['errorCode'] = 0; + $rData['errorString'] = "Account " . $pData->username . " created."; + } + else { + $rData['result'] = 'DENIED'; + $rData['errorCode'] = 2; + $rData['errorString'] = "Account " . $pData->username . " already exissts."; + } + break; + case "login": + if ($pData->username == "test@zirror.com" && $pData->password == "osx") { + $rData['result'] = 'GRANTED'; + $rData['errorCode'] = 0; + $rData['errorString'] = "Access Granted"; + $rData['accessToken'] = time(); + } + else { + $rData['result'] = 'DENIED'; + $rData['errorCode'] = 1; + $rData['errorString'] = "Access Denied"; + $rData['accessToken'] = 0; + } + break; + default: + $rData['SexTask'] = 'Eat Cock'; + $rData['SexTaskPartner'] = 'Anyone You Desire'; + $rData['SexTaxTime'] = 'Right Now'; +} + +print (json_encode($rData)); + +?> diff --git a/docroot/session.php b/docroot/session.php new file mode 100755 index 0000000..c8f0c7a --- /dev/null +++ b/docroot/session.php @@ -0,0 +1,21 @@ + "session", "cmd" => "newSession"); + +var_dump($data); +print json_encode($data); + + +?>