| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>DefaultSessionContext (Apache Shiro 1.13.0 API)</title> |
| <link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="DefaultSessionContext (Apache Shiro 1.13.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":10,"i1":10,"i2":10,"i3":10}; |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- Matomo --> <script> var _paq = window._paq = window._paq || []; /* tracker methods like "setCustomDimension" should be called before "trackPageView" */ /* We explicitly disable cookie tracking to avoid privacy issues */ _paq.push(['disableCookies']); _paq.push(['trackPageView']); _paq.push(['enableLinkTracking']); (function() { var u="//matomo.privacy.apache.org/"; _paq.push(['setTrackerUrl', u+'matomo.php']); _paq.push(['setSiteId', '2']); var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s); })(); </script> <!-- End Matomo Code --> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/DefaultSessionContext.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/apache/shiro/session/mgt/AbstractValidatingSessionManager.html" title="class in org.apache.shiro.session.mgt"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionKey.html" title="class in org.apache.shiro.session.mgt"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/apache/shiro/session/mgt/DefaultSessionContext.html" target="_top">Frames</a></li> |
| <li><a href="DefaultSessionContext.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">org.apache.shiro.session.mgt</div> |
| <h2 title="Class DefaultSessionContext" class="title">Class DefaultSessionContext</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li><a href="../../../../../org/apache/shiro/util/MapContext.html" title="class in org.apache.shiro.util">org.apache.shiro.util.MapContext</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.apache.shiro.session.mgt.DefaultSessionContext</li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><a href="https://docs.oracle.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a><<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>>, <a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></dd> |
| </dl> |
| <dl> |
| <dt>Direct Known Subclasses:</dt> |
| <dd><a href="../../../../../org/apache/shiro/web/session/mgt/DefaultWebSessionContext.html" title="class in org.apache.shiro.web.session.mgt">DefaultWebSessionContext</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public class <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.33">DefaultSessionContext</a> |
| extends <a href="../../../../../org/apache/shiro/util/MapContext.html" title="class in org.apache.shiro.util">MapContext</a> |
| implements <a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></pre> |
| <div class="block">Default implementation of the <a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt"><code>SessionContext</code></a> interface which provides getters and setters that |
| wrap interaction with the underlying backing context map.</div> |
| <dl> |
| <dt><span class="simpleTagLabel">Since:</span></dt> |
| <dd>1.0</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../serialized-form.html#org.apache.shiro.session.mgt.DefaultSessionContext">Serialized Form</a></dd> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested.class.summary"> |
| <!-- --> |
| </a> |
| <h3>Nested Class Summary</h3> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested.classes.inherited.from.class.java.util.Map"> |
| <!-- --> |
| </a> |
| <h3>Nested classes/interfaces inherited from interface java.util.<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a></h3> |
| <code><a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">Map.Entry</a><<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">K</a>,<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">V</a>></code></li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colOne" scope="col">Constructor and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#DefaultSessionContext--">DefaultSessionContext</a></span>()</code> </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#DefaultSessionContext-java.util.Map-">DefaultSessionContext</a></span>(<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a><<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>> map)</code> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#getHost--">getHost</a></span>()</code> |
| <div class="block">Returns the originating host name or IP address (as a String) from where the <code>Subject</code> is initiating the |
| <code>Session</code>.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#getSessionId--">getSessionId</a></span>()</code> </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#setHost-java.lang.String-">setHost</a></span>(<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> host)</code> |
| <div class="block">Sets the originating host name or IP address (as a String) from where the <code>Subject</code> is initiating the |
| <code>Session</code>.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionContext.html#setSessionId-java.io.Serializable-">setSessionId</a></span>(<a href="https://docs.oracle.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a> sessionId)</code> </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.org.apache.shiro.util.MapContext"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class org.apache.shiro.util.<a href="../../../../../org/apache/shiro/util/MapContext.html" title="class in org.apache.shiro.util">MapContext</a></h3> |
| <code><a href="../../../../../org/apache/shiro/util/MapContext.html#clear--">clear</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#containsKey-java.lang.Object-">containsKey</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#containsValue-java.lang.Object-">containsValue</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#entrySet--">entrySet</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#get-java.lang.Object-">get</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#getTypedValue-java.lang.String-java.lang.Class-">getTypedValue</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#isEmpty--">isEmpty</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#keySet--">keySet</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#nullSafePut-java.lang.String-java.lang.Object-">nullSafePut</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#put-java.lang.String-java.lang.Object-">put</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#putAll-java.util.Map-">putAll</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#remove-java.lang.Object-">remove</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#size--">size</a>, <a href="../../../../../org/apache/shiro/util/MapContext.html#values--">values</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> |
| <code><a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.java.util.Map"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface java.util.<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a></h3> |
| <code><a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#clear--" title="class or interface in java.util">clear</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#compute-K-java.util.function.BiFunction-" title="class or interface in java.util">compute</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#computeIfAbsent-K-java.util.function.Function-" title="class or interface in java.util">computeIfAbsent</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#computeIfPresent-K-java.util.function.BiFunction-" title="class or interface in java.util">computeIfPresent</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#containsKey-java.lang.Object-" title="class or interface in java.util">containsKey</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#containsValue-java.lang.Object-" title="class or interface in java.util">containsValue</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#entrySet--" title="class or interface in java.util">entrySet</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.util">equals</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#forEach-java.util.function.BiConsumer-" title="class or interface in java.util">forEach</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#get-java.lang.Object-" title="class or interface in java.util">get</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#getOrDefault-java.lang.Object-V-" title="class or interface in java.util">getOrDefault</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#hashCode--" title="class or interface in java.util">hashCode</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#isEmpty--" title="class or interface in java.util">isEmpty</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#keySet--" title="class or interface in java.util">keySet</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#merge-K-V-java.util.function.BiFunction-" title="class or interface in java.util">merge</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#put-K-V-" title="class or interface in java.util">put</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#putAll-java.util.Map-" title="class or interface in java.util">putAll</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#putIfAbsent-K-V-" title="class or interface in java.util">putIfAbsent</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#remove-java.lang.Object-" title="class or interface in java.util">remove</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#remove-java.lang.Object-java.lang.Object-" title="class or interface in java.util">remove</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#replace-K-V-" title="class or interface in java.util">replace</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#replace-K-V-V-" title="class or interface in java.util">replace</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#replaceAll-java.util.function.BiFunction-" title="class or interface in java.util">replaceAll</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#size--" title="class or interface in java.util">size</a>, <a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true#values--" title="class or interface in java.util">values</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="DefaultSessionContext--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>DefaultSessionContext</h4> |
| <pre>public <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.40">DefaultSessionContext</a>()</pre> |
| </li> |
| </ul> |
| <a name="DefaultSessionContext-java.util.Map-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>DefaultSessionContext</h4> |
| <pre>public <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.44">DefaultSessionContext</a>(<a href="https://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a><<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>> map)</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="getHost--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getHost</h4> |
| <pre>public <a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.48">getHost</a>()</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#getHost--">SessionContext</a></code></span></div> |
| <div class="block">Returns the originating host name or IP address (as a String) from where the <code>Subject</code> is initiating the |
| <code>Session</code>. |
| <p/> |
| See the <a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#setHost-java.lang.String-"><code>setHost(String)</code></a> JavaDoc for more about security policies based on the |
| <code>Session</code> host.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#getHost--">getHost</a></code> in interface <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the originating host name or IP address (as a String) from where the <code>Subject</code> is initiating the |
| <code>Session</code>.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#setHost-java.lang.String-"><code>setHost(String)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setHost-java.lang.String-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setHost</h4> |
| <pre>public void <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.52">setHost</a>(<a href="https://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> host)</pre> |
| <div class="block"><span class="descfrmTypeLabel">Description copied from interface: <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#setHost-java.lang.String-">SessionContext</a></code></span></div> |
| <div class="block">Sets the originating host name or IP address (as a String) from where the <code>Subject</code> is initiating the |
| <code>Session</code>. |
| <p/> |
| In web-based systems, this host can be inferred from the incoming request, e.g. |
| <code>javax.servlet.ServletRequest#getRemoteAddr()</code> or <code>javax.servlet.ServletRequest#getRemoteHost()</code> |
| methods, or in socket-based systems, it can be obtained via inspecting the socket |
| initiator's host IP. |
| <p/> |
| Most secure environments <em>should</em> specify a valid, non-<code>null</code> <code>host</code>, since knowing the |
| <code>host</code> allows for more flexibility when securing a system: by requiring an host, access control policies |
| can also ensure access is restricted to specific client <em>locations</em> in addition to <code>Subject</code> |
| principals, if so desired. |
| <p/> |
| <b>Caveat</b> - if clients to your system are on a |
| public network (as would be the case for a public web site), odds are high the clients can be |
| behind a NAT (Network Address Translation) router or HTTP proxy server. If so, all clients |
| accessing your system behind that router or proxy will have the same originating host. |
| If your system is configured to allow only one session per host, then the next request from a |
| different NAT or proxy client will fail and access will be denied for that client. Just be |
| aware that host-based security policies are best utilized in LAN or private WAN environments |
| when you can be ensure clients will not share IPs or be behind such NAT routers or |
| proxy servers.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#setHost-java.lang.String-">setHost</a></code> in interface <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>host</code> - the originating host name or IP address (as a String) from where the <code>Subject</code> is |
| initiating the <code>Session</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getSessionId--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getSessionId</h4> |
| <pre>public <a href="https://docs.oracle.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a> <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.58">getSessionId</a>()</pre> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#getSessionId--">getSessionId</a></code> in interface <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="setSessionId-java.io.Serializable-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>setSessionId</h4> |
| <pre>public void <a href="../../../../../src-html/org/apache/shiro/session/mgt/DefaultSessionContext.html#line.62">setSessionId</a>(<a href="https://docs.oracle.com/javase/6/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a> sessionId)</pre> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html#setSessionId-java.io.Serializable-">setSessionId</a></code> in interface <code><a href="../../../../../org/apache/shiro/session/mgt/SessionContext.html" title="interface in org.apache.shiro.session.mgt">SessionContext</a></code></dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/DefaultSessionContext.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../../../org/apache/shiro/session/mgt/AbstractValidatingSessionManager.html" title="class in org.apache.shiro.session.mgt"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../../../org/apache/shiro/session/mgt/DefaultSessionKey.html" title="class in org.apache.shiro.session.mgt"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../../index.html?org/apache/shiro/session/mgt/DefaultSessionContext.html" target="_top">Frames</a></li> |
| <li><a href="DefaultSessionContext.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2004–2023 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |