aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-12-01 14:46:17 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-12-01 14:46:17 +1300
commit0e5e61fd14486e6b926b83895eedf9c97c2cb342 (patch)
tree9652071a03638a06145750795a95be44241878a9 /src
parenta4fb24732188e4e0b7cc44079eea02c85e142028 (diff)
downloadtraccar-server-0e5e61fd14486e6b926b83895eedf9c97c2cb342.tar.gz
traccar-server-0e5e61fd14486e6b926b83895eedf9c97c2cb342.tar.bz2
traccar-server-0e5e61fd14486e6b926b83895eedf9c97c2cb342.zip
Minor cleanup of security context class
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/api/SecurityContextApi.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/org/traccar/api/SecurityContextApi.java b/src/org/traccar/api/SecurityContextApi.java
index df10340c5..38ce7e33d 100644
--- a/src/org/traccar/api/SecurityContextApi.java
+++ b/src/org/traccar/api/SecurityContextApi.java
@@ -20,18 +20,12 @@ import javax.ws.rs.core.SecurityContext;
public class SecurityContextApi implements SecurityContext {
- private static final String AUTHENTICATION_SCHEME = "BASIC";
- private static final boolean IS_SECURE = true;
-
private Principal userPrincipal;
public SecurityContextApi(Principal userPrincipal) {
this.userPrincipal = userPrincipal;
}
- public SecurityContextApi() {
- }
-
@Override
public Principal getUserPrincipal() {
return userPrincipal;
@@ -45,11 +39,12 @@ public class SecurityContextApi implements SecurityContext {
@Override
public boolean isSecure() {
- return IS_SECURE;
+ return false;
}
@Override
public String getAuthenticationScheme() {
- return AUTHENTICATION_SCHEME;
+ return BASIC_AUTH;
}
+
}