‎2009 Mar 10 9:01 AM
hi all,
i have the following requirement regarding password given by the user .
i have to check the following things on the password entered by user at the time of registeration and also while resetting the password , this is a ecommerce scenario and i will get that password in abap throgh a bapi
1.the password should contains alpha numeric characters
2.password length should be greater than 6.
Is there any std function module on ABAP to achieve this or is there any configuration setting to achieve this
please help me..
Thanks and Regards
shanto aloor
‎2009 Mar 10 9:08 AM
use the below FM's ..
BAPI_EMPLOYEE_CHANGEPASSWORD
BAPI_EMPLOYEE_CHECKPASSWORD
‎2009 Mar 10 10:35 AM
hi srini,
we are using CRM6.0 and this FM's are not available.
i will explain once again my requirement.
user will enter a password in webshop and the java people will send the information to bapi inside that bapi i have to check whether the password string contains a combination of characters,special characters and numbers.
please suggest a suitable solution for this in abap coding.
Thanks and Regards
shanto aloor
‎2009 Mar 10 10:37 AM
Hi,
You can try the following:
data: password1 TYPE c LENGTH 10 VALUE 'gfertw1',
password2 TYPE c LENGTH 10 VALUE 'G001',
password3 TYPE c LENGTH 10 VALUE 'gfer=w1',
lv_char TYPE c LENGTH 37,
lv_len TYPE n.
CONCATENATE sy-abcde '0123456789' INTO lv_char SEPARATED BY ' '.
TRANSLATE password1 TO UPPER CASE.
CONDENSE password2.
if password1 CO lv_char .
write:/ 'success1'.
else.
write:/ 'error1'.
endif.
if password2 CO lv_char.
write:/ 'success2'.
else.
write:/ 'error2'.
endif.
if password3 CO lv_char.
write:/ 'success3'.
else.
write:/ 'error3'.
endif.
2.password length should be greater than 6.
lv_len = strlen( password1 ).
if lv_len <= 6.
"error
endif.
Regards