← Back to team overview

openerp-community team mailing list archive

Re: AccessDenied on OpenERP 6.1's XMLRPC on specific database

 

I tried enabling "debug_rpc_answer" log level and I see *"search"*operations
like this one:

2013-03-21 04:19:58,619 21422 INFO ? werkzeug: 192.168.1.52 - -
[21/Mar/2013 04:19:58] "POST /xmlrpc/common HTTP/1.0" 200 -
2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
object.execute('MDI',
2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
     1,
2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
     '*',
2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
     'res.company',
2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
     'search',
2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
     [['name', '=', u'Mercadeo Din\xe1mico del Itsmo S.A.']])
*2013-03-21 04:44:08,888 21656 DEBUG ? openerp.netsvc.rpc.response:
object.execute time:0.006s [1]*


But when a "*read*" operation is executed, the request is logged but no
response is generated, no error appears in log file, and the "AccessDenied"
is sent to the XMLRPC client:

2013-03-21 04:44:08,898 21656 INFO ? werkzeug: 192.168.1.52 - -
[21/Mar/2013 04:44:08] "POST /xmlrpc/object HTTP/1.0" 200 -
2013-03-21 04:44:08,901 21656 DEBUG ? openerp.netsvc.rpc.request:
object.execute('MDI', 1, '*', 'res.company', 'read', [1], ['currency_id'])

(No debug message about response generation when a "read" operation is
performed).

I have no idea why these AccessDenied are not logged and why the response
is not being generated and logged correctly.

*Another hint to get fine-grained debug logs?*


2013/3/20 Jonathan Vargas <jvargas@xxxxxxxxx>

> I tried enabling "debug_rpc_answer" log level and I see *"search"*operations like this one:
>
> 2013-03-21 04:19:58,619 21422 INFO ? werkzeug: 192.168.1.52 - -
> [21/Mar/2013 04:19:58] "POST /xmlrpc/common HTTP/1.0" 200 -
> 2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
> object.execute('MDI',
> 2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
>        1,
> 2013-03-21 04:44:08,883 21656 DEBUG ? openerp.netsvc.rpc.request:
>        '*',
> 2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
>        'res.company',
> 2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
>        'search',
> 2013-03-21 04:44:08,884 21656 DEBUG ? openerp.netsvc.rpc.request:
>        [['name', '=', u'Mercadeo Din\xe1mico del Itsmo S.A.']])
> *2013-03-21 04:44:08,888 21656 DEBUG ? openerp.netsvc.rpc.response:
> object.execute time:0.006s [1]*
>
>
> But when a "*read*" operation is executed, the request is logged but no
> response is generated, no error appears in log file, and the "AccessDenied"
> is sent to the XMLRPC client:
>
> 2013-03-21 04:44:08,898 21656 INFO ? werkzeug: 192.168.1.52 - -
> [21/Mar/2013 04:44:08] "POST /xmlrpc/object HTTP/1.0" 200 -
> 2013-03-21 04:44:08,901 21656 DEBUG ? openerp.netsvc.rpc.request:
> object.execute('MDI', 1, '*', 'res.company', 'read', [1], ['currency_id'])
>
> (No debug message about response generation when a "read" operation is
> performed).
>
> I have no idea why these AccessDenied are not logged and why the response
> is not being generated and logged correctly.
>
> *Another hint to get fine-grained debug logs?*
>
>
>
>
> 2013/3/19 Martin Collins <martin@xxxxxxxxxxxxx>
>
>> On 19/03/13 18:56, Jonathan Vargas wrote:
>>
>>>
>>> I checked group's permission on res.company object, on both development
>>> and production databases, and they seem to be the same.
>>>
>>
>> Sounds like you have missing permissions for some other object, perhaps
>> the
>> bank info. The ORM will cause a cascading effect on all the related models
>> when you read which you don't get with a search.
>>
>> Try running the server in debug mode and/or check the log. It will
>> probably
>> tell you which object denies access.
>>
>> Martin
>>
>> ______________________________**_________________
>> Mailing list: https://launchpad.net/~**openerp-community<https://launchpad.net/~openerp-community>
>> Post to     : openerp-community@lists.**launchpad.net<openerp-community@xxxxxxxxxxxxxxxxxxx>
>> Unsubscribe : https://launchpad.net/~**openerp-community<https://launchpad.net/~openerp-community>
>> More help   : https://help.launchpad.net/**ListHelp<https://help.launchpad.net/ListHelp>
>>
>
>
>
> --
> *Jonathan Vargas Rodríguez*
> IT Business Solution Developer
> Alkaid · Open Source Business Software
> Office: 2553 5467, Mobile: 8568 3307
> Web: alkaid.cr | E-mail: jvargas@xxxxxxxxx
>
> *Your business needs + Our technical skills = Benefits.
> That's my job. Don't be afraid to contact me*  :-)
>
>


-- 
*Jonathan Vargas Rodríguez*
IT Business Solution Developer
Alkaid · Open Source Business Software
Office: 2553 5467, Mobile: 8568 3307
Web: alkaid.cr | E-mail: jvargas@xxxxxxxxx

*Your business needs + Our technical skills = Benefits.
That's my job. Don't be afraid to contact me*  :-)

Follow ups

References