A very simple solution is to use a filter that checks whether a method has a
particular annotation.

My auth methods have an annotation called @AuthRequired that will only
succeed if the user is ok and then inject that user into my resources.


On Tue, Jul 19, 2011 at 11:00 AM, Bruno Fuster <brunofus...@gmail.com>wrote:

> Hi Rob,
>
> I'm developing an iphone app using GAE as a RESTful back-end and I've
> implemented my own auth using HTTP Digest over SSL.
>
> RESTful services should be stateless, so each authenticated call should
> send the user information (tokens or login/pass). To Login, just create a
> service that returns HTTP Codes 200 or 403 if login succeed or failed.
>
> Hope it helps.
>
> Regards,
>
>
>
> On Mon, Jul 18, 2011 at 11:59 PM, Rob <r...@conaway58.com> wrote:
>
>> I'd like to create a RESTful web service in GAE.  I want to restrict
>> access with authentication.  I want to call the service from a Java program
>> that is run unattended.
>>
>> How can I authenticate from the Java program?  I see ClientLogin, but that
>> seems to be oriented toward an interactive application where the user can
>> respond to a captcha, if necessary.  That's not practical in my case.
>>
>> ---
>>
>> My reason for needing this is that I have a Java application using OFX4j
>> to read bank transactions from a checking account.  I'd like to store these
>> transactions in a GAE datastore for later access.  I cannot use OFX4j
>> directly in GAE because it uses sockets.  So I will periodically run the
>> Java application as a cron job.  It will call the RESTful web service in GAE
>> to store the data.
>>
>> Thank you for any help.
>>
>> Rob
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Google App Engine for Java" group.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msg/google-appengine-java/-/d4Svj1CJb-sJ.
>> To post to this group, send email to
>> google-appengine-java@googlegroups.com.
>> To unsubscribe from this group, send email to
>> google-appengine-java+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/google-appengine-java?hl=en.
>>
>
>
>
> --
> Bruno Fuster
>
>


-- 
Bruno Fuster

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to