Skip to content

Commit

Permalink
Use realm as domain, instead of hostname
Browse files Browse the repository at this point in the history
  • Loading branch information
thc202 committed Apr 25, 2016
1 parent 4fe6562 commit 4d76a3e
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,10 @@ public WebSession authenticate(SessionManagementMethod sessionManagementMethod,
AuthScope stateAuthScope = null;
NTCredentials stateCredentials = null;
try {
stateAuthScope = new AuthScope(this.hostname, this.port,
(this.realm == null || this.realm.isEmpty()) ? AuthScope.ANY_REALM : this.realm);
stateAuthScope = new AuthScope(this.hostname, this.port, AuthScope.ANY_REALM);
stateCredentials = new NTCredentials(userCredentials.getUsername(),
userCredentials.getPassword(), InetAddress.getLocalHost().getCanonicalHostName(),
this.hostname);
this.realm);
session.getHttpState().setCredentials(stateAuthScope, stateCredentials);
} catch (UnknownHostException e1) {
log.error(e1.getMessage(), e1);
Expand Down

0 comments on commit 4d76a3e

Please sign in to comment.