java - Unable to Access Shared Folders in Our Own Machine using NTLM: unknown user name or bad password -
i working on ntlm implementation java. trying access shared folders inside own machine. following exception:
jcifs.smb.smbauthexception: logon failure: unknown user name or bad password.
i got machine name , workgroup info computer properties. here code:
string folderurl =settings.domain+";"+settings.username+":"+settings.password ntlmpasswordauthentication authentication = new ntlmpasswordauthentication("${folderurl}") ; smbfile readfolder = new smbfile("smb:"+settings.fileslocation+"/",authentication) ;
and in line above exception:
smbfile[] listoffiles = readfolder.listfiles() ;
solution tried far:
i made change in local security policy , change value of "network security: lan manager authentication level" "send nlm & ntlm, use session security if negotiated" in vain. furthermore, tried changing password , domain well.
note:
- i have created shared folders , these visible in 'network' shared
- i unable access machine through other machines on same network, don't know why, may reason. have @ error when try access machine other machine on same network same credential use enter in pc:
please guide me how can make application access these shared folders on network path using ntlm?
in case, issue windows login user (don't know issue actually) using access shared folder. so, created new windows user , tried access shared folders newly created window user , shared folders accessible without issue.
alongwith new user machine accessible others machine on same network.
Comments
Post a Comment