I can access the client drive if they have admin rights using the below code (can create and write files) but what if the client machine does not have admin rights, how to access their machine drive using below code?
public static void main(String[] args) throws Exception {
String url = "smb://182.16.109.161/C$/";
try {
NtlmPasswordAuthentication auth = new NtlmPasswordAuthentication(null, "username", "password");
SmbFile dir = new SmbFile(url, auth);
for (SmbFile f : dir.listFiles())
{
System.out.println(f.getName());
}
} catch (Exception e) {
e.printStackTrace();
}
}