title: AngularJS HTTP headers config. Response for preflight has invalid HTTP status code 401
body: <p>I'm trying to get a Rest service with angular:</p>
  
  <pre><code>angular.module('coursExoApp').factory('serviceAjax', function ($http) {
  return{
      objects: function(){
           var test=$http({
              method: 'GET',
              url: 'http://------------/Windchill/servlet/rest/changes/objects/getReports',
              headers: {
                  'Authorization': 'Basic d2NhZG1pbjp3Y2FkbWlu'           
              }
              }).
              success(function(data, status, headers, config) {
                  console.log('success');
              }).
              error(function(data, status, headers, config) {
                  console.log(config);
              });
  
              return test;
      }
  }});
  </code></pre>
  
  <p>and i'm getting this error:
  <a href="http://i.stack.imgur.com/ZjhqS.png" rel="nofollow" title="image">IMAGE HERE</a></p>
  
  <p>The service with basic authentification works fine with postMan.
  thanks for help</p>