本文整理了Java中org.eclipse.jetty.server.Request.isSecure
方法的一些代码示例,展示了Request.isSecure
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Request.isSecure
方法的具体详情如下:
包路径:org.eclipse.jetty.server.Request
类名称:Request
方法名:isSecure
暂无
代码示例来源:origin: jersey/jersey
@Override
public boolean isSecure() {
return request.isSecure();
}
代码示例来源:origin: org.keycloak/keycloak-jetty-adapter-spi
@Override
public boolean isSecure() {
return request.isSecure();
}
代码示例来源:origin: org.keycloak/spring-boot-container-bundle
@Override
public boolean isSecure() {
return request.isSecure();
}
代码示例来源:origin: org.eclipse.jetty/jetty-security
if (request.isSecure())
return true;
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
AbstractHttpConnection connection = AbstractHttpConnection.getCurrentConnection();
if (connection == null)
return;
Request request = connection.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSessionManager.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
AbstractHttpConnection connection = AbstractHttpConnection.getCurrentConnection();
if (connection == null)
return;
Request request = connection.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSessionManager.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
AbstractHttpConnection connection = AbstractHttpConnection.getCurrentConnection();
if (connection == null)
return;
Request request = connection.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSessionManager.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: org.eclipse.jetty/security
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
AbstractHttpConnection connection = AbstractHttpConnection.getCurrentConnection();
if (connection == null)
return;
Request request = connection.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSessionManager.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
@Override
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
HttpChannel<?> channel = HttpChannel.getCurrentHttpChannel();
if (channel == null)
return;
Request request = channel.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
@Override
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
HttpChannel<?> channel = HttpChannel.getCurrentHttpChannel();
if (channel == null)
return;
Request request = channel.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: Nextdoor/bender
@Override
public void sessionCreated(HttpSessionEvent se)
{
//if current request is authenticated, then as we have just created the session, mark it as secure, as it has not yet been returned to a user
HttpChannel<?> channel = HttpChannel.getCurrentHttpChannel();
if (channel == null)
return;
Request request = channel.getRequest();
if (request == null)
return;
if (request.isSecure())
{
se.getSession().setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
}
}
});
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
@Override
public void customize(EndPoint endpoint, Request request) throws IOException
{
super.customize(endpoint,request);
if (request.isSecure())
request.setScheme(HttpSchemes.HTTPS);
}
代码示例来源:origin: com.opentable.components/otj-server-core
@Override
public void customize(Connector connector, HttpConfiguration channelConfig, Request request) {
super.customize(connector, channelConfig, request);
if (!request.isSecure()) {
super.customizeSecure(request);
}
}
}
代码示例来源:origin: org.restlet.jee/org.restlet.ext.jetty
/**
* Indicates if the request was made using a confidential mean.<br>
*
* @return True if the request was made using a confidential mean.<br>
*/
@Override
public boolean isConfidential() {
return getConnection().getRequest().isSecure();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
public HttpSession getSession(boolean create)
{
if (_session != null)
{
if (_sessionManager != null && !_sessionManager.isValid(_session))
_session = null;
else
return _session;
}
if (!create)
return null;
if (_sessionManager == null)
throw new IllegalStateException("No SessionManager");
_session = _sessionManager.newHttpSession(this);
HttpCookie cookie = _sessionManager.getSessionCookie(_session,getContextPath(),isSecure());
if (cookie != null)
_connection.getResponse().addCookie(cookie);
return _session;
}
代码示例来源:origin: at.bestsolution.efxclipse.eclipse/org.eclipse.jetty.server
public String changeSessionId()
{
HttpSession session = getSession(false);
if (session == null)
throw new IllegalStateException("No session");
if (session instanceof AbstractSession)
{
AbstractSession abstractSession = ((AbstractSession)session);
abstractSession.renewId(this);
if (getRemoteUser() != null)
abstractSession.setAttribute(AbstractSession.SESSION_CREATED_SECURE, Boolean.TRUE);
if (abstractSession.isIdChanged())
_channel.getResponse().addCookie(_sessionManager.getSessionCookie(abstractSession, getContextPath(), isSecure()));
}
return session.getId();
}
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
public String changeSessionId()
{
HttpSession session = getSession(false);
if (session == null)
throw new IllegalStateException("No session");
if (session instanceof AbstractSession)
{
AbstractSession abstractSession = ((AbstractSession)session);
abstractSession.renewId(this);
if (getRemoteUser() != null)
abstractSession.setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
if (abstractSession.isIdChanged())
_channel.getResponse().addCookie(_sessionManager.getSessionCookie(abstractSession, getContextPath(), isSecure()));
}
return session.getId();
}
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
public String changeSessionId()
{
HttpSession session = getSession(false);
if (session == null)
throw new IllegalStateException("No session");
if (session instanceof AbstractSession)
{
AbstractSession abstractSession = ((AbstractSession)session);
abstractSession.renewId(this);
if (getRemoteUser() != null)
abstractSession.setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
if (abstractSession.isIdChanged())
_channel.getResponse().addCookie(_sessionManager.getSessionCookie(abstractSession, getContextPath(), isSecure()));
}
return session.getId();
}
代码示例来源:origin: Nextdoor/bender
public String changeSessionId()
{
HttpSession session = getSession(false);
if (session == null)
throw new IllegalStateException("No session");
if (session instanceof AbstractSession)
{
AbstractSession abstractSession = ((AbstractSession)session);
abstractSession.renewId(this);
if (getRemoteUser() != null)
abstractSession.setAttribute(AbstractSession.SESSION_KNOWN_ONLY_TO_AUTHENTICATED, Boolean.TRUE);
if (abstractSession.isIdChanged())
_channel.getResponse().addCookie(_sessionManager.getSessionCookie(abstractSession, getContextPath(), isSecure()));
}
return session.getId();
}
代码示例来源:origin: jenkinsci/winstone
@Override
public String changeSessionId()
{
HttpSession session = getSession(false);
if (session == null)
throw new IllegalStateException("No session");
if (session instanceof Session)
{
Session s = ((Session)session);
s.renewId(this);
if (getRemoteUser() != null)
s.setAttribute(Session.SESSION_CREATED_SECURE, Boolean.TRUE);
if (s.isIdChanged() && _sessionHandler.isUsingCookies())
_channel.getResponse().addCookie(_sessionHandler.getSessionCookie(s, getContextPath(), isSecure()));
}
return session.getId();
}
内容来源于网络,如有侵权,请联系作者删除!