Skip to content
Permalink
Browse files

Overriding the default values for token properties enabled.

  • Loading branch information
little-pinecone committed Jan 14, 2019
1 parent acb38f8 commit 1b80e70533f4823086c7aefb556884452aa311e9
@@ -46,6 +46,8 @@ $ ng test

Set the `apiUrl` const in `frontend/src/main/angular/src/environments/environment.prod.ts` to the path for the production environment.

Override the default `TokenProperties` values. E.g. to override the expiration time of tokens you can add `security.jwt.expiration=your_value` to the `application.properties` file.

## Built With

* Java 11
@@ -1,9 +1,9 @@
package in.keepgrowing.jwtspringbootangularscaffolding.security;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Service;
import org.springframework.stereotype.Component;

@Service
@Component
@ConfigurationProperties(prefix = "security.jwt")
public class TokenProperties {

@@ -21,19 +21,39 @@ public String getLoginPath() {
return loginPath;
}

public void setLoginPath(String loginPath) {
this.loginPath = loginPath;
}

public String getHeader() {
return header;
}

public void setHeader(String header) {
this.header = header;
}

public String getPrefix() {
return prefix;
}

public void setPrefix(String prefix) {
this.prefix = prefix;
}

public int getExpiration() {
return expiration;
}

public void setExpiration(int expiration) {
this.expiration = expiration;
}

public String getSecret() {
return secret;
}

public void setSecret(String secret) {
this.secret = secret;
}
}

0 comments on commit 1b80e70

Please sign in to comment.
You can’t perform that action at this time.