apparently have to add_permission like
user = auth.login_bare("user", "pwd")
auth.add_permission(impersonateGroupID, "impersonate", db.auth_user,0)
auth.impersonate(46)
return auth.user_id
Em qui., 16 de jan. de 2020 às 15:46, António Ramos
escreveu:
> bad english in previous e
bad english in previous email. Sorry about that.
the user sysadmin belongs to group "impersonate" ike attached pic in
previous email.
My code to impersonate user sysadmin as user 25 returns "Forbidden"
any help ?
Regards
António
Em qui., 16 de jan. de 2020 às 15:42, António Ramos
escreveu:
>
Back again to impersonate issue. I have the sysadmin user member of
impersonate like the attached pic.
[image: image.png]
My code to impersonate user 25 as follows "Forbidden"
def execdal():
user=auth.login_bare("sysadmin","mypwd")
auth.impersonate(25)
return dict(a=user)
Em qua., 1
found it
Had to create a group called "impersonate"
then added my user to that membership
then
in my function
user=auth.login_bare("teslaoneday","youwish...")
user=auth.impersonate(25)
Not it works as expected...
Regards
Em qua., 18 de dez. de 2019 às 17:41, António Ramos
escreveu:
> h
4 matches
Mail list logo