Subversion Repositories personal-webbase

Rev

Rev 12 | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. <?php
  2.  
  3. if (!defined('WBLEGAL')) die('Kann nicht ohne Personal WebBase ausgef&uuml;hrt werden.');
  4.  
  5. if ($wb_user_type == 0)
  6. {
  7.   die($header.'Diese Funktion ist im Gastzugang nicht verf&uuml;gbar.'.$footer);
  8. }
  9.  
  10. if (($konfiguration['core_fastlogin_access']['enabled']) && (isset($benutzer['fastlogin_secret'])) && ($benutzer['fastlogin_secret'] != ''))
  11. {
  12.   if (!headers_sent()) header("Pragma: public");
  13.   if (!headers_sent()) header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
  14.   if (!headers_sent()) header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
  15.   if (!headers_sent()) header("Cache-Control: private",false);
  16.   if (!headers_sent()) header("Content-type: application/octet-stream");
  17.   if (!headers_sent()) header("Content-Disposition: attachment; filename=\"Personal WebBase-Direktzugang.url\"");
  18.   if (!headers_sent()) header("Content-Transfer-Encoding: binary");
  19.  
  20.   $secret_key  = $ib_user_username."\n";
  21.   $secret_key .= special_hash($ib_user_username)."\n";
  22.   $secret_key .= $ib_user_passwort."\n";
  23.   $secret_key .= special_hash($ib_user_passwort);
  24.   $secret_key  = ib_encrypt($secret_key, $benutzer['fastlogin_secret']);
  25.  
  26.   if ($force_ssl)
  27.     $ibs_prae = 'https://';
  28.   else
  29.     $ibs_prae = 'http://';
  30.  
  31.   $ibs  = $ibs_prae;
  32.   $ibs .= $_SERVER['HTTP_HOST'];
  33.   $ibs .= $_SERVER['PHP_SELF'];
  34.  
  35.   $inh = $ibs.'?modul=core_fastlogin_access&seite=run&secretkey='.urlencode($secret_key)."\r\n";
  36.  
  37.   echo "[InternetShortcut]\r\nURL=$inh";
  38.  
  39.   if (file_exists('favicon.ico'))
  40.   {
  41.     $ibs2  = $ibs_prae;
  42.     $ibs2 .= $_SERVER['HTTP_HOST'];
  43.     $ibs2 .= dirname_with_pathdelimiter($_SERVER['PHP_SELF']);
  44.  
  45.     echo "IconFile=$ibs2favicon.ico\r\nIconIndex=1\r\n";
  46.   }
  47. }
  48. else
  49. {
  50.   die($header.'Die Schnellanmeldung ist deaktiviert.'.$footer);
  51. }
  52.  
  53. ?>
  54.