Thanks for the reply, I have already read that section prior to sending my
email :D

I am still unclear. I know how to handle the login when in a web browser.
However when using the RPC server I just get the following response:

send: 'POST /api/default/call/jsonrpc HTTP/1.1\r\nHost:
127.0.0.1:8000\r\nAccept-Encoding:
gzip\r\nUser-Agent: xmlrpclib.py/1.0.1 (by www.pythonware.com)\r\nContent-Type:
application/json\r\nContent-Length: 62\r\n\r\n'
send: '{"params": [1, 2], "id": 6641919632256610108, "method": "add"}'
reply: 'HTTP/1.1 303 SEE OTHER\r\n'
header: Set-Cookie:
 session_id_api=127.0.0.1-b7adcc1a-ae18-4010-a20c-12e37d3e0c55; Path=/
header: Content-Type: text/html; charset=UTF-8
header: Location: /api/default/user/login?_next=/api/default/call/jsonrpc
header: Date: Thu, 05 Jan 2012 20:51:49 GMT
header: Server: Rocket 1.2.4 Python/2.7.2+
header: Content-Length: 99
header: Connection: keep-alive
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "gluon/contrib/simplejsonrpc.py", line 106, in <lambda>
    return lambda *args: self.call(attr, *args)
  File "gluon/contrib/simplejsonrpc.py", line 121, in call
    verbose=self.__verbose
  File "/usr/lib/python2.7/xmlrpclib.py", line 1264, in request
    return self.single_request(host, handler, request_body, verbose)
  File "/usr/lib/python2.7/xmlrpclib.py", line 1312, in single_request
    response.msg,
xmlrpclib.ProtocolError: <ProtocolError for
127.0.0.1:8000/api/default/call/jsonrpc: 303 SEE OTHER>


On Thu, Jan 5, 2012 at 2:43 PM, Alan Etkin <spame...@gmail.com> wrote:

> On services and authentication there is a section in the book that
> gives an example, as posted by Anthony in another thread:
>
> http://web2py.com/books/default/chapter/29/10?search=services+and+authentication#Services-and-Authentication
>
> Thread on similar topic:
>
> http://groups.google.com/group/web2py/browse_thread/thread/fa1ada23498e2b30/34bd1ef34aadd230?lnk=gst&q=Authentication+using+xmlrpc#34bd1ef34aadd230
>



-- 
-- 
Regards,
Bruce Wade
http://ca.linkedin.com/in/brucelwade
http://www.wadecybertech.com
http://www.warplydesigned.com
http://www.fitnessfriendsfinder.com

Reply via email to