Wiki | Explorer | Navigator | Complexes | Build | Item info | Rigs | Cans | Security | Rats | Ore | Changes (Aug 05 '07)

Grismar's EVE Wiki : TrustInformation

WikiHome :: Categories :: PageIndex :: RecentChanges :: RecentlyCommented :: Login/Register

IGB Header


This article explains how to get the header IGB sends along with page requests when your page is trusted, what information is in it and how to ask the browser to request trust from the user.

If you need to know how to trust a webpage using the IGB, or want to know more about trust in general, read TrustPage.

Getting trust, reading the header


Here's a piece of code you can use to get the header from the IGB, if you're using PHP:

      $browser = $HTTP_SERVER_VARS['HTTP_USER_AGENT'];
      $ingame = (substr($browser,0,16)=='EVE-minibrowser/');
     
      function get_trust() {
        global $ingame, $trusted, $pilotname;
        if ($ingame) {
         // check for trust 
           if ($_SERVER['HTTP_EVE_TRUSTED']=='no') {
            // request trust from client through headers
              header("eve.trustme:".$this_host."/::please allow me to access your pilot information.");
              $trusted = false;
           } else {
              $trusted = true;
            // get pilotname
              $pilotname = $_SERVER['HTTP_EVE_CHARNAME'];
           }
        }
      }
   
      get_trust();


Note that the IGB will always send HTTP_EVE_TRUSTED along, regardless if the page is trusted or not. Depending on the value ('yes' or 'no'), you can read the rest of the header variables.

Note that the routine is trying to modify the headers for the page. Depending on the configuration of your webserver, it may start sending headers as soon as you start outputting html from the script. Use ob_start()leaving this site and ob_end_flush()leaving this site in php to buffer output until you're done with the page, or at least until you're done modifying headers.

Information in the header

The following information will be sent along in the header, if the user has your webpage or domain in the trusted sites list.


The corprole is a bitmask, you can perform a logical and with the following values and it will result in that same value if the bit is set or in 0 if the bit is clear.

CorproleBit
Director1
Personnel Manager128
Accountant256
Security Officer512
Factory Manager1024
Station Manager2048
Auditor4096
Hangar Can Take Division 18192
Hangar Can Take Division 216384
Hangar Can Take Division 332768
Hangar Can Take Division 465536
Hangar Can Take Division 5131072
Hangar Can Take Division 6262144
Hangar Can Take Division 7524288
Hangar Can Query Division 11048576
Hangar Can Query Division 22097152
Hangar Can Query Division 34194304
Hangar Can Query Division 48388608
Hangar Can Query Division 516777216
Hangar Can Query Division 633554432
Hangar Can Query Division 767108864
Account Can Take Division 1134217728
Account Can Take Division 2268435456
Account Can Take Division 3536870912
Account Can Take Division 41073741824
Account Can Take Division 52147483648
Account Can Take Division 64294967296
Account Can Take Division 78589934592
Account Can Query Division 117179869184
Account Can Query Division 234359738368
Account Can Query Division 368719476736
Account Can Query Division 4137438953472
Account Can Query Division 5274877906944
Account Can Query Division 6549755813888
Account Can Query Division 71099511627776
Equipment Config2199023255552
ContainerCan Take Division 14398046511104
ContainerCan Take Division 28796093022208
ContainerCan Take Division 317592186044416
ContainerCan Take Division 435184372088832
ContainerCan Take Division 570368744177664
ContainerCan Take Division 6140737488355328
ContainerCan Take Division 7281474976710656
Can Rent Office562949953421312
Can Rent FactorySlot1125899906842624
Can Rent ResearchSlot2251799813685248
Junior Accountant4503599627370496
Starbase Config9007199254740992
Trader18014398509481984



Current EVE version: 2.14.28028 (Revelations I)

There are no comments on this page. [Add comment]

Valid XHTML 1.0 Transitionalleaving this site :: Valid CSSleaving this site :: Powered by Wikka Wakka Wiki 1.1.6.2leaving this site
Page was generated in 0.0979 seconds