title: how to get an openstack token and validate it?
body: <p>I followed this guide: <a href="http://keystone.openstack.org/api_curl_examples.html" rel="noreferrer">http://keystone.openstack.org/api_curl_examples.html</a></p>
  
  <p>and it seemed that I got a valid token by ran:</p>
  
  <pre><code>curl -d '{"auth":{"passwordCredentials":{"username": "can", "password": "mypassword"}}}' -H "Content-type: application/json" http://url:35357/v2.0/tokens
  </code></pre>
  
  <p>and it returned:</p>
  
  <pre><code>{
  "access": 
  {
      "token": 
      {
          "expires": "2012-05-21T14:35:17Z", 
          "id": "468da447bd1c4821bbc5def0498fd441"
      }, 
      "serviceCatalog": {}, 
      "user": 
      {
          "username": "can",
          "roles_links": [],
          "id": "bb6d3a09ad0c4924bf20c1a32ccb5781",
          "roles": [],
          "name": "can"
      }
  }
  }
  </code></pre>
  
  <p>but when I came to the next few sections to validate this token, I encountered this magic number: <code>X-Auth-Token:999888777666</code>. <strong>At first I thought it's the token I got but I was wrong.</strong></p>
  
  <p>I think I may have missed something, so I read related sections in openstack documents( <a href="http://keystone.openstack.org/configuration.html" rel="noreferrer">http://keystone.openstack.org/configuration.html</a> and <a href="http://docs.openstack.org/api/openstack-compute/programmer/content/" rel="noreferrer">http://docs.openstack.org/api/openstack-compute/programmer/content/</a> ), but still no idea how the number comes from.</p>
  
  <p>could anyone explain to me </p>
  
  <ol>
  <li>what's the meaning of that magic number</li>
  <li>how to get the right value of it so I can get a working token to manage other parts of openstack</li>
  </ol>