plugins/SpecialUserFuncs.php
changeset 321 c0d855cfaf0e
parent 317 f8356d9c3481
child 324 16d0c9f33466
equal deleted inserted replaced
320:112debff64bd 321:c0d855cfaf0e
   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