title: Is it possible to get attributes in a CAS response without phpCAS?
body: <p>We are using CAS on several sites with phpCAS. It returns a response with the username and a number of attributes like email and display name.</p>
  
  <p>So the following echoes out all of the attributes (Full name, email, etc...)</p>
  
  <pre><code>&lt;?php
  foreach (phpCAS::getAttributes() as $key =&gt; $value) {
  if (is_array($value)) {
  echo '&lt;li&gt;', $key, ':&lt;ol&gt;';
  foreach($value as $item) {
        echo '&lt;li&gt;&lt;strong&gt;', $item, '&lt;/strong&gt;&lt;/li&gt;';
      }
  echo '&lt;/ol&gt;&lt;/li&gt;';
  } else {
      echo '&lt;li&gt;', $key, ': &lt;strong&gt;', $value, '&lt;/strong&gt;&lt;/li&gt;';
    }
  }
  ?&gt;
  </code></pre>
  
  <p>Right now, I'm trying to see if I can do this without phpCAS so we can share it as a plugin without requiring users to have phpCAS installed.</p>
  
  <p>I'm getting a response and I'm able to authenticate users so, basically, it works but I'm only getting the username in the response. What do I need to do to get those attributes without phpCAS?</p>
  
  <p>If I understand correctly, this might have something to do with declaring SAML which might be requered to get attributes:</p>
  
  <pre><code>phpCAS::client(SAML_VERSION_1_1, $cas_host, $cas_port, $cas_context);
  </code></pre>
  
  <p>So, maybe my question should be, is there a way to accomplish this same thing without phpCAS?</p>