Hi Folks,

I had Services and AMFPHP running nicely for a while now and have been using it on a Flash project.

As instructed by the mighty Drupal Update gods I downloaded all the fresh new updates and now I can't access services.

I see there is some new authorization coolness going on but it's wiped out my site.

Firstly: What is an authorization module and where do I get one?
My searches haven't found anything yet (probably because I don't know what I am looking for).

If I do get one, will services go back to normal?

If I am calling Drupal via Flash am I going to have to add a load of new parameters to my call to access Drupal?

I think I'll have to put the old services back in, because this is frankly quite scary with deadlines looming.
But I would like to know where to find all the info for the new services as I am not pulling anything up.

Thanks.

Comments

marcingy’s picture

If you:
* go to the modules page, enable the key auth module
* go to the services settings page and select key auth from the dropdown

Then everything will go back to normal.

If you were using keys before you need to go to the keys tab after doing the above steps, click on edited for a key and allow the required services.

Hope this helps

Marc

Bensbury’s picture

Wow!
Thanks for the fast response.

I think the important thing is that the Key Auth Module needs to be enabled in the Modules List.

I had no idea what it was or where to look for it.
I guess it comes with the new Services but needs to be enabled in the Module Settings because when I installed the new Services there were no options to select a Authorization Module and the searches on Drupal for "Authorization Module" ;) are non-existent.

Thanks a lot for pointing me in the right direction. That was fully scary.

I am really interested in how to get keys and such working with Flash and Services but things like Nonces and creating hash values seem a bit full without seriously getting stuck into it.

However, maybe I am just a bit thick but perhaps a little note telling people they need to enable Authorization Module in the Modules list will save folks like me cluttering the issues list. :)

Cheers.

marcingy’s picture

Title: NewServices! - Help!@ Flash site Down.....@%$ » Changes to services module - see this if you are having issues with access after installing new dev version

I agree I'll put together a module handbook page tomorrow - for now I'll change the title of the issue you have raised.

In addition I'll add an prompt for the admin so as they know a extra step needs to be carried out if no services authenication module has been enabled.

Glad that solved your issue :)

Bensbury’s picture

Thanks.

Just as a side issue: Where can I find out the information for using key authentication?
I've found this aspect really mysterious but would like to get it working in Flash w/AMFPHP&Services and it looks like Services is moving into making this mandatory, which is great for security, but seemingly hyper techy for the less knowledgeable.

marcingy’s picture

No services is not moving to make it mandatory, infact the opposite. We are in the processing of making session auth its own authenication module (http://drupal.org/node/465546). The new plugin system we have introduced allows additional authenication methods to be defined eg Oauth. Basically we are trying to make the integrating with services as flexible as possible. You can find some information about key based security here http://drupal.org/node/394224.

amitaibu’s picture

Even after I enable the authentication I get access denied. From debugging the code, it seems that the wrong values are passed for example to node_service_get_access() - the authentication keys instead of the node ID.

marcingy’s picture

Can you provide some more info about your set up are you using keys? If so have you edited the key in question to set the method to be accessible? The reason why I ask is because I can't replicate locally and correct parameter is most certainly being passed in.

amitaibu’s picture

Ok, regarding #6 - issue was solved when I added in the Keys >> Domains = localhost.
Maybe we should make this field required?

marcingy’s picture

We are working on improving the upgrade path to carry over old settings hopefully this patch will be committed in the next couple of days and will resolve issues people are having.

parkijp’s picture

Hi,

I have today installed the 6.x-1.x-dev services module. When using the admin/build/services/browse/node.get page to test the service, I enter a node id (nid) such as "1" and click call method. The only response I get is "Access Denied". I have the key authentication module enabled and I have given the anonymous user access to the "administer services" option under services module and "node load data" under node_service module. Is there anything else I am missing?

Quick update on my progress with this issue:

If I disable the option to "use keys" in the settings and also remove the if statement from line 435 of services.module (as per instructions in this post http://drupal.org/node/473214) I can get the xmlrpc services to work. So it doesn't work if "use keys" is enabled.

Cheers.

marcingy’s picture

Have you enabled the method for the given key?

parkijp’s picture

Thank you for your reply.

I did have the methods enabled for the key. My problem was that I didn't have the domain in the test method match the domain of one of my keys. (I'd read a similar issue above but misunderstood it's relevance). It is now working like a dream.

Cheers.

marcingy’s picture

Version: 6.x-1.x-dev » 6.x-2.x-dev
gdd’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.