View Javadoc

1   /*
2    * Copyright [2005] [University Corporation for Advanced Internet Development, Inc.]
3    *
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.apache.org/licenses/LICENSE-2.0
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  
17  package org.opensaml.saml2.core;
18  
19  import javax.xml.namespace.QName;
20  
21  import org.opensaml.common.xml.SAMLConstants;
22  import org.opensaml.xml.schema.XSBooleanValue;
23  
24  /**
25   * SAML 2.0 Core AuthnRequest.
26   */
27  public interface AuthnRequest extends RequestAbstractType {
28  
29      /** Element local name. */
30      public static final String DEFAULT_ELEMENT_LOCAL_NAME = "AuthnRequest";
31  
32      /** Default element name. */
33      public static final QName DEFAULT_ELEMENT_NAME = new QName(SAMLConstants.SAML20P_NS, DEFAULT_ELEMENT_LOCAL_NAME,
34              SAMLConstants.SAML20P_PREFIX);
35  
36      /** Local name of the XSI type. */
37      public static final String TYPE_LOCAL_NAME = "AuthnRequestType";
38  
39      /** QName of the XSI type. */
40      public static final QName TYPE_NAME = new QName(SAMLConstants.SAML20P_NS, TYPE_LOCAL_NAME,
41              SAMLConstants.SAML20P_PREFIX);
42  
43      /** ForceAuthn attribute name. */
44      public static final String FORCE_AUTHN_ATTRIB_NAME = "ForceAuthn";
45  
46      /** IsPassive attribute name. */
47      public static final String IS_PASSIVE_ATTRIB_NAME = "IsPassive";
48  
49      /** ProtocolBinding attribute name. */
50      public static final String PROTOCOL_BINDING_ATTRIB_NAME = "ProtocolBinding";
51  
52      /** AssertionConsumerServiceIndex attribute name. */
53      public static final String ASSERTION_CONSUMER_SERVICE_INDEX_ATTRIB_NAME = "AssertionConsumerServiceIndex";
54  
55      /** AssertionConsumerServiceURL attribute name. */
56      public static final String ASSERTION_CONSUMER_SERVICE_URL_ATTRIB_NAME = "AssertionConsumerServiceURL";
57  
58      /** AttributeConsumingServiceIndex attribute name. */
59      public static final String ATTRIBUTE_CONSUMING_SERVICE_INDEX_ATTRIB_NAME = "AttributeConsumingServiceIndex";
60  
61      /** ProviderName attribute name. */
62      public static final String PROVIDER_NAME_ATTRIB_NAME = "ProviderName";
63  
64      /**
65       * Gets whether the IdP should force the user to reauthenticate.
66       * 
67       * @return whether the IdP should force the user to reauthenticate
68       */
69      public Boolean isForceAuthn();
70  
71      /**
72       * Gets whether the IdP should force the user to reauthenticate.
73       * 
74       * @return whether the IdP should force the user to reauthenticate
75       */
76      public XSBooleanValue isForceAuthnXSBoolean();
77  
78      /**
79       * Sets whether the IdP should force the user to reauthenticate. Boolean values will be marshalled to either "true"
80       * or "false".
81       * 
82       * @param newForceAuthn whether the IdP should force the user to reauthenticate
83       */
84      public void setForceAuthn(Boolean newForceAuthn);
85  
86      /**
87       * Sets whether the IdP should force the user to reauthenticate.
88       * 
89       * @param newForceAuthn whether the IdP should force the user to reauthenticate
90       */
91      public void setForceAuthn(XSBooleanValue newForceAuthn);
92  
93      /**
94       * Gets whether the IdP should refrain from interacting with the user during the authentication process.
95       * 
96       * @return whether the IdP should refrain from interacting with the user during the authentication process
97       */
98      public Boolean isPassive();
99  
100     /**
101      * Gets whether the IdP should refrain from interacting with the user during the authentication process.
102      * 
103      * @return whether the IdP should refrain from interacting with the user during the authentication process
104      */
105     public XSBooleanValue isPassiveXSBoolean();
106 
107     /**
108      * Sets whether the IdP should refrain from interacting with the user during the authentication process. Boolean
109      * values will be marshalled to either "true" or "false".
110      * 
111      * @param newIsPassive whether the IdP should refrain from interacting with the user during the authentication
112      *            process
113      */
114     public void setIsPassive(Boolean newIsPassive);
115 
116     /**
117      * Sets whether the IdP should refrain from interacting with the user during the authentication process.
118      * 
119      * @param newIsPassive whether the IdP should refrain from interacting with the user during the authentication
120      *            process
121      */
122     public void setIsPassive(XSBooleanValue newIsPassive);
123 
124     /**
125      * Gets the protocol binding URI for the request.
126      * 
127      * @return the value of the ProtocolBinding attribute
128      */
129     public String getProtocolBinding();
130 
131     /**
132      * Sets the protocol binding URI for the request.
133      * 
134      * @param newProtocolBinding the new value of the ProtocolBinding attribute
135      */
136     public void setProtocolBinding(String newProtocolBinding);
137 
138     /**
139      * Gets the index of the particular Assertion Consumer Service to which the response to this request should be
140      * delivered.
141      * 
142      * @return the value of the AssertionConsumerServiceIndex attribute
143      */
144     public Integer getAssertionConsumerServiceIndex();
145 
146     /**
147      * Sets the index of the particular Assertion Consumer Service to which the response to this request should be
148      * delivered.
149      * 
150      * @param newAssertionConsumerServiceIndex the new value of the AssertionConsumerServiceIndex attribute
151      */
152     public void setAssertionConsumerServiceIndex(Integer newAssertionConsumerServiceIndex);
153 
154     /**
155      * Gets the URL of the particular Assertion Consumer Service to which the response to this request should be
156      * delivered.
157      * 
158      * @return the value of the AssertionConsumerServiceURL attribute
159      */
160     public String getAssertionConsumerServiceURL();
161 
162     /**
163      * Sets the URL of the particular Assertion Consumer Service to which the response to this request should be
164      * delivered.
165      * 
166      * @param newAssertionConsumerServiceURL the new value of the AssertionConsumerServiceURL attribute
167      */
168     public void setAssertionConsumerServiceURL(String newAssertionConsumerServiceURL);
169 
170     /**
171      * Gets the index of the Attribute Consuming Service which describes the SAML attributes the requester desires or
172      * requires to be supplied in the <code>Response</code> message.
173      * 
174      * 
175      * @return the value of the AssertionConsumerServiceIndex attribute
176      */
177     public Integer getAttributeConsumingServiceIndex();
178 
179     /**
180      * 
181      * Sets the index of the Attribute Consuming Service which describes the SAML attributes the requester desires or
182      * requires to be supplied in the <code>Response</code> message.
183      * 
184      * @param newAttributeConsumingServiceIndex the new value of the AttributeConsumingServiceIndex attribute
185      */
186     public void setAttributeConsumingServiceIndex(Integer newAttributeConsumingServiceIndex);
187 
188     /**
189      * Gets the human-readable name of the requester for use by the presenter's user agent or the identity provider.
190      * 
191      * @return the value of the ProviderName attribute
192      */
193     public String getProviderName();
194 
195     /**
196      * Sets the human-readable name of the requester for use by the presenter's user agent or the identity provider.
197      * 
198      * @param newProviderName the new value of the ProviderName attribute
199      */
200     public void setProviderName(String newProviderName);
201 
202     /**
203      * Gets the {@link Subject} of the request.
204      * 
205      * @return the Subject of the request
206      */
207     public Subject getSubject();
208 
209     /**
210      * Sets the {@link Subject} of the request.
211      * 
212      * @param newSubject the new value of the Subject of the request
213      */
214     public void setSubject(Subject newSubject);
215 
216     /**
217      * Gets the {@link NameIDPolicy} of the request.
218      * 
219      * @return the NameIDPolicy of the request
220      */
221     public NameIDPolicy getNameIDPolicy();
222 
223     /**
224      * Sets the {@link NameIDPolicy} of the request.
225      * 
226      * @param newNameIDPolicy the new value of the NameIDPolicy of the request
227      */
228     public void setNameIDPolicy(NameIDPolicy newNameIDPolicy);
229 
230     /**
231      * Gets the {@link Conditions} of the request.
232      * 
233      * @return the Conditions of the request
234      */
235     public Conditions getConditions();
236 
237     /**
238      * Sets the {@link Conditions} of the request.
239      * 
240      * @param newConditions the new value of the Conditions of the request
241      */
242     public void setConditions(Conditions newConditions);
243 
244     /**
245      * Gets the {@link RequestedAuthnContext} of the request.
246      * 
247      * @return the RequestedAuthnContext of the request
248      */
249     public RequestedAuthnContext getRequestedAuthnContext();
250 
251     /**
252      * Sets the {@link RequestedAuthnContext} of the request.
253      * 
254      * @param newRequestedAuthnContext the new value of the RequestedAuthnContext of the request
255      */
256     public void setRequestedAuthnContext(RequestedAuthnContext newRequestedAuthnContext);
257 
258     /**
259      * Gets the {@link Scoping} of the request.
260      * 
261      * @return the Scoping of the request
262      */
263     public Scoping getScoping();
264 
265     /**
266      * Sets the {@link Scoping} of the request.
267      * 
268      * @param newScoping the new value of the Scoping of the request
269      */
270     public void setScoping(Scoping newScoping);
271 
272 }