‎2006 Nov 13 1:53 PM
'Hi,
How can we check authorisation in RFC function module.I have a unique requirement where I need to find authorisation to cost center object in RFC function module.But when we make RFC,its sy-uname will be different from calling program's sy-uname.Obviously authority-check will not work within RFC function modules.How can I get around the requirement.your help will be rewarded.
Thanks & Regds
Surendranath
‎2006 Nov 13 1:59 PM
Hi surendranath,
1. Such authorisation should be done
BEFORE calling the RFC.
2. The RFC should be called only if the authoirsation is successsful,
in the CALLING Program.
3. Even suppose its possible to know the sy-uname,
then how are we going to check the authorisation,
in THE CALLING SERVER ?
regards,
amit m.
‎2006 Nov 13 1:59 PM
Hi surendranath,
1. Such authorisation should be done
BEFORE calling the RFC.
2. The RFC should be called only if the authoirsation is successsful,
in the CALLING Program.
3. Even suppose its possible to know the sy-uname,
then how are we going to check the authorisation,
in THE CALLING SERVER ?
regards,
amit m.
‎2006 Nov 13 2:02 PM
Hi amit,
you are correct if I am calling RFC from ABAP.My case is I am calling from Guixt(third party tool which sits on GUI).
Regds
Surendranath
‎2006 Nov 13 2:06 PM
If the calling application is run online and the application is not using a generic user id for all users, then the calling application can pass the user name as a parameter to the RFC. This can then be used for authority checks.
Let me know if this can work.
Cheers
‎2006 Nov 13 2:13 PM
Hi Kiran,
authority-check will check the authorisation for the current user(sy-uname) implicitly.If I am not wrong, passing sy-uname to RFC FM is of no use..Still I am looking out the avenue if I could get what I want by digging some tables.At the end every thing in SAP will be stored in tables..
Thanks & Regds
Surendranath
‎2006 Nov 13 2:04 PM
Hi Surendra
If the RFC FM is for one time (to use in one program or in a few programs) I guess, you can Export the necesorry data from RFC to the calling program(s) and perform the authority check in the program(s).
If you go for this option maintain appropriate documentation for the FM to avoid confusions.
Regards
Surya.