This topic contains 6 replies, has 2 voices, and was last updated by Alexandr Smaga 9 years, 4 months ago.
- Topic
Hi guys,
I’m trying to get some info using REST Api. I followed all the steps from “How to use WSSE authentication“.
First point. I think this is outdated because it doesn’t accept username. Only the API KEY:
php app/console oro:wsse:generate-header username
123app/console oro:wsse:generate-header my_username[InvalidArgumentException]API key "my_username" does not existsSo, using the API Key:
crm-enterprise-application$app/console oro:wsse:generate-header 20cb1b48abc8d305de31aeca2791d829d0b0a33a
To use WSSE authentication add following headers to the request:
Authorization: WSSE profile=”UsernameToken”
X-WSSE: UsernameToken Username=”my_username”, PasswordDigest=”HdUCOD9LeX+wDSx2hCRp3jv8oMo=”, Nonce=”ZTZlOGEzNDE0ZDI3YzY1ZA==”, Created=”2014-12-09T14:15:04-05:00″crm-enterprise-application$
curl -i -H “Accept: application/json” -H ‘Authorization: WSSE profile=”UsernameToken”‘ -H ‘X-WSSE: UsernameToken Username=”my_username”, PasswordDigest=”HdUCOD9LeX+wDSx2hCRp3jv8oMo=”, Nonce=”ZTZlOGEzNDE0ZDI3YzY1ZA==”, Created=”2014-12-09T14:15:04-05:00″‘ http://oro-production.local/app_dev.php/api/rest/latest/usersHTTP/1.1 500 Internal Server Error
Date: Tue, 09 Dec 2014 19:15:29 GMT
Server: Apache/2.2.26 (Unix) mod_fastcgi/2.4.6 mod_wsgi/3.4 Python/2.7.6 PHP/5.5.14 mod_ssl/2.2.26 OpenSSL/0.9.8za DAV/2 mod_perl/2.0.8 Perl/v5.18.2
X-Powered-By: PHP/5.5.14
Cache-Control: no-cache
X-Debug-Token: f23608
Connection: close
Transfer-Encoding: chunked
Content-Type: application/json{“status”:”error”,”status_code”:500,”status_text”:”Internal Server Error”,”current_content”:””,”message”:”This token has no \”digest\” attribute.“}
crm-enterprise-application$
Thanks!
My version:
Oro: 1.4.2/1.6.2
The forum ‘OroCRM – Programming Questions’ is closed to new topics and replies.