plugins/SpecialUserFuncs.php
changeset 263 16d0c9f33466
parent 261 5f1cd51bf1be
parent 260 c0d855cfaf0e
child 274 f725a16e4a20
equal deleted inserted replaced
262:a82133ce2d76 263:16d0c9f33466
   104   $pubkey = $session->rijndael_genkey();
   104   $pubkey = $session->rijndael_genkey();
   105   $challenge = $session->dss_rand();
   105   $challenge = $session->dss_rand();
   106   
   106   
   107   if ( isset($_GET['act']) && $_GET['act'] == 'getkey' )
   107   if ( isset($_GET['act']) && $_GET['act'] == 'getkey' )
   108   {
   108   {
       
   109     header('Content-type: application/json');
   109     $username = ( $session->user_logged_in ) ? $session->username : false;
   110     $username = ( $session->user_logged_in ) ? $session->username : false;
   110     $response = Array(
   111     $response = Array(
   111       'username' => $username,
   112       'username' => $username,
   112       'key' => $pubkey,
   113       'key' => $pubkey,
   113       'challenge' => $challenge
   114       'challenge' => $challenge