I find a way to pass current user credentials by default to my rest call in java.I start application by a specific user and I dont want to enter password information in my rest call(spring resttemplate or something similar to call a rest service)
In c# UseDefaultCredentials =true gives this capability when LDAP authentication is active I try to find similar way.
//c# code
HttpClient client = new HttpClient(new HttpClientHandler() { UseDefaultCredentials = true });