public class Hsts extends Object
| 构造器和说明 |
|---|
Hsts() |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
getEnabled()
返回是否启用 Hsts
|
Boolean |
getIncludeSubDomains()
返回此规则是否适也用于该网站的所有子域名
|
Class<? extends org.springframework.security.web.util.matcher.RequestMatcher> |
getMatcher()
返回 Request 匹配器类
|
Long |
getMaxAge()
返回缓存时间,在浏览器收到这个请求后的 maxAge 秒的时间内凡是访问这个域名下的请求都使用HTTPS请求
|
Boolean |
getPreload()
返回是否预加载 HSTS
|
boolean |
isEnabled()
返回是否启用 Hsts
|
boolean |
isIncludeSubDomains()
已过时。
|
Boolean |
isPreload()
已过时。
|
void |
setEnabled(boolean enabled)
配置是否启用 Hsts
|
void |
setIncludeSubDomains(Boolean includeSubDomains)
设置此规则是否也适用于该网站的所有子域名
|
void |
setMatcher(Class<? extends org.springframework.security.web.util.matcher.RequestMatcher> matcher)
设置 Request 匹配器类
|
void |
setMaxAge(Long maxAge)
设置缓存时间,设置在浏览器收到这个请求后的 maxAge 秒的时间内凡是访问这个域名下的请求都使用HTTPS请求
|
void |
setPreload(Boolean preload)
设置是否预加载 HSTS
|
String |
toString() |
public boolean isEnabled()
public boolean getEnabled()
public void setEnabled(boolean enabled)
enabled - 是否启用 Hstspublic Class<? extends org.springframework.security.web.util.matcher.RequestMatcher> getMatcher()
public void setMatcher(Class<? extends org.springframework.security.web.util.matcher.RequestMatcher> matcher)
matcher - Request 匹配器类public Long getMaxAge()
public void setMaxAge(Long maxAge)
maxAge - 缓存时间(单位:秒)@Deprecated public boolean isIncludeSubDomains()
public Boolean getIncludeSubDomains()
public void setIncludeSubDomains(Boolean includeSubDomains)
includeSubDomains - 此规则是否也适用于该网站的所有子域名@Deprecated public Boolean isPreload()
public Boolean getPreload()
public void setPreload(Boolean preload)
preload - 是否预加载 HSTSCopyright © 2022 buession.com Inc.. All rights reserved.