Plus Emulator Security Fixes

Page 5 of 5 FirstFirst 12345
Results 61 to 63 of 63
  1. #61
    Registered DinamicUser is offline
    MemberRank
    Dec 2013 Join Date
    ItalyLocation
    15Posts

    Re: Plus Emulator Security Fixes


    RaGEZONE Recommends

    RaGEZONE Recommends

    SSO FIX for RevCMS

    Pastebin
    Last edited by DinamicUser; 20-06-17 at 01:42 AM.

  2. #62
    o/ Konquer is online now
    True MemberRank
    Apr 2014 Join Date
    312Posts

    Re: Plus Emulator Security Fixes

    Quote Originally Posted by DinamicUser View Post
    SSO FIX for RevCMS

    Spoiler:
    /*----------------------------------------Create SSO auth_ticket-------------------------------------*/ final public function createSSO($k) { $sessionKey = ''.rand(9,9999999).''.substr(sha1(time()).''.rand(9,9999999).''.rand(9,9999999).''.rand(9,9999999),0,33); $this->updateUser($k, 'auth_ticket', $sessionKey); $sql = mysql_query("SELECT `user_id` FROM `user_auth_ticket` WHERE `user_id` = '".$k."'"); if(mysql_num_rows($sql) > 0){ mysql_query("UPDATE `user_auth_ticket` SET `auth_ticket` = '".$sessionKey."' WHERE `user_id` = '".$k."'"); }else{ mysql_query("INSERT INTO `user_auth_ticket` (`user_id`, `auth_ticket`) VALUES ('".$k."', '".$sessionKey."');"); } unset($sessionKey); }
    People generally want to know what something does before they copy pasterino it into their cms.

    Also, you should probably tell people which file the existing method can be found in. Also also, the formatting of your code makes my eyes bleed.
    Lurking around

  3. #63
    Hardcore Member BeginOfEnd is offline
    MemberRank
    Dec 2015 Join Date
    The NetherlandsLocation
    109Posts

    Re: Plus Emulator Security Fixes

    Quote Originally Posted by DinamicUser View Post
    SSO FIX for RevCMS

    Spoiler:
    /*----------------------------------------Create SSO auth_ticket-------------------------------------*/ final public function createSSO($k) { $sessionKey = ''.rand(9,9999999).''.substr(sha1(time()).''.rand(9,9999999).''.rand(9,9999999).''.rand(9,9999999),0,33); $this->updateUser($k, 'auth_ticket', $sessionKey); $sql = mysql_query("SELECT `user_id` FROM `user_auth_ticket` WHERE `user_id` = '".$k."'"); if(mysql_num_rows($sql) > 0){ mysql_query("UPDATE `user_auth_ticket` SET `auth_ticket` = '".$sessionKey."' WHERE `user_id` = '".$k."'"); }else{ mysql_query("INSERT INTO `user_auth_ticket` (`user_id`, `auth_ticket`) VALUES ('".$k."', '".$sessionKey."');"); } unset($sessionKey); }
    Already posted: Help with SSO




Page 5 of 5 FirstFirst 12345

Advertisement