Posted: Sat Jun 07, 2008 10:56 am Post subject: Synchronize password accross clients
Synchronize password accross clients. (Warning !! this report makes an update directly against the data base)
Code:
REPORT ZSYNC_PASSWORD message-id zaut.
*----------------------------------------------------------------------*
* Beskrivelse: Programmet synkroniserer password pе tvжrs alle *
* klienter. Det password der bliver distribueret ud *
* er det password man har pе den klient er er logget pе *
* *
* Man kan med dette program ikke se passwordet, og man *
* kan ikke angive et nyt password, ligesom at programmet *
* ikke unlocker brugeren hvis denne er locked *
* Med dette program kan man heller ikke synkroniserer *
* det initiale password ud pе andre klienter, da *
* afviklingen af programmet krжver at man er logget pе *
* *
* Autorisation: For at kunne synkroniserer password for andre brugere *
* end den bruger der er logget pе krжvet der at man er *
* autorisationsobjekt ZSYNC_PASS = '59' *
* *
* Afvikling: Programmet afvikles i forgrunden *
* *
* Parametre: USER - intialer pе den bruger der skal have synkronis- *
* ret password *
*----------------------------------------------------------------------*
TABLES: USR02, T000.
DATA: PASSWD LIKE USR02-BCODE.
PARAMETERS: USER LIKE USR02-BNAME default sy-uname.
SELECT SINGLE * FROM USR02 WHERE BNAME = USER.
*IF SY-UNAME <> 'SAP*'.
* WRITE: / 'Only SAP* is allowed to run this program'. EXIT.
*ENDIF.
IF SY-SUBRC <> 0.
message i001 with user.
exit .
ENDIF.
IF USER NE SY-UNAME.
AUTHORITY-CHECK OBJECT 'ZSYNC_PASS'
ID 'ACTVT' FIELD '59'.
if sy-subrc <> 0.
message i002 with user.
exit .
endif.
endif.
PASSWD = USR02-BCODE.
CLEAR USR02.
WRITE: / 'Passwordet for', USER, 'er synkroniseret i klienterne:'.
SELECT * FROM T000 WHERE MANDT <> SY-MANDT.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
All product names are trademarks of their respective companies. SAPNET.RU websites are in no way affiliated with SAP AG. SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver and any other are registered trademarks of SAP AG. Every effort is made to ensure content integrity. Use information on this site at your own risk.