File: Auth_OpenID_Consumer.html

package info (click to toggle)
php-openid 2.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 3,284 kB
  • ctags: 6,733
  • sloc: php: 20,482; python: 346; xml: 333; sh: 130; perl: 103; makefile: 31
file content (229 lines) | stat: -rw-r--r-- 13,053 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Auth_OpenID_Consumer</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			

<h2 class="class-name">Class Auth_OpenID_Consumer</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">An OpenID consumer implementation that performs discovery and does  session management.  See the Consumer.php file documentation for  more information.</p>
		<p class="notes">
			Located in <a class="field" href="_Auth---OpenID---Consumer.php.html">/Auth/OpenID/Consumer.php</a> (line <span class="field">214</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>




	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
												<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																														
				<div class="method-definition">
											<span class="method-result">Auth_OpenID_Consumer</span>
										<a href="#Auth_OpenID_Consumer" title="details" class="method-name">Auth_OpenID_Consumer</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">&$store</span>, [<span class="var-type">mixed</span>&nbsp;<span class="var-name">$session</span> = <span class="var-default">null</span>], [<span class="var-type">str</span>&nbsp;<span class="var-name">$consumer_cls</span> = <span class="var-default">null</span>], <span class="var-type"><a href="../OpenID/Auth_OpenID_OpenIDStore.html">Auth_OpenID_OpenIDStore</a></span>&nbsp;<span class="var-name">$store</span>)
									</div>
														
				<div class="method-definition">
											<span class="method-result"><a href="../OpenID/Auth_OpenID_AuthRequest.html">Auth_OpenID_AuthRequest</a></span>
										<a href="#begin" title="details" class="method-name">begin</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$user_url</span>, [<span class="var-type">bool</span>&nbsp;<span class="var-name">$anonymous</span> = <span class="var-default">false</span>])
									</div>
														
				<div class="method-definition">
											<span class="method-result"><a href="../OpenID/Auth_OpenID_AuthRequest.html">Auth_OpenID_AuthRequest</a></span>
										<a href="#beginWithoutDiscovery" title="details" class="method-name">&amp;beginWithoutDiscovery</a>
											(<span class="var-type">Auth_OpenID_ServiceEndpoint</span>&nbsp;<span class="var-name">$endpoint</span>, [<span class="var-type">bool</span>&nbsp;<span class="var-name">$anonymous</span> = <span class="var-default">false</span>])
									</div>
														
				<div class="method-definition">
											<span class="method-result"><a href="../OpenID/Auth_OpenID_ConsumerResponse.html">Auth_OpenID_ConsumerResponse</a></span>
										<a href="#complete" title="details" class="method-name">complete</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$return_to</span>, [<span class="var-type">array</span>&nbsp;<span class="var-name">$query</span> = <span class="var-default">null</span>])
									</div>
											</div>
		</div>
	</div>		

	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>
<a name="methodAuth_OpenID_Consumer" id="Auth_OpenID_Consumer"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">Constructor Auth_OpenID_Consumer</span> (line <span class="line-number">260</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Initialize a Consumer instance.</p>
<p class="description"><p>You should create a new instance of the Consumer object with  every HTTP request that handles OpenID transactions.</p></p>
	
	<div class="method-signature">
		<span class="method-result">Auth_OpenID_Consumer</span>
		<span class="method-name">
			Auth_OpenID_Consumer
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">&$store</span>, [<span class="var-type">mixed</span>&nbsp;<span class="var-name">$session</span> = <span class="var-default">null</span>], [<span class="var-type">str</span>&nbsp;<span class="var-name">$consumer_cls</span> = <span class="var-default">null</span>], <span class="var-type"><a href="../OpenID/Auth_OpenID_OpenIDStore.html">Auth_OpenID_OpenIDStore</a></span>&nbsp;<span class="var-name">$store</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../OpenID/Auth_OpenID_OpenIDStore.html">Auth_OpenID_OpenIDStore</a></span>
				<span class="var-name">$store</span><span class="var-description">: This must be an object  that implements the interface in <a href="../OpenID/Auth_OpenID_OpenIDStore.html">Auth_OpenID_OpenIDStore</a>.  Several concrete implementations are  provided, to cover most common use cases.  For stores backed by  MySQL, PostgreSQL, or SQLite, see the <a href="../OpenID/Auth_OpenID_SQLStore.html">Auth_OpenID_SQLStore</a> class and its sublcasses.  For a  filesystem-backed store, see the <a href="../OpenID/Auth_OpenID_FileStore.html">Auth_OpenID_FileStore</a>  module.  As a last resort, if it isn't possible for the server  to store state at all, an instance of <a href="../OpenID/Auth_OpenID_DumbStore.html">Auth_OpenID_DumbStore</a> can be used.</span>			</li>
					<li>
				<span class="var-type">mixed</span>
				<span class="var-name">$session</span><span class="var-description">: An object which implements the interface  of the <a href="../OpenID/Auth_Yadis_PHPSession.html">Auth_Yadis_PHPSession</a> class.  Particularly, this  object is expected to have these methods: get($key), set($key),  $value), and del($key).  This defaults to a session object  which wraps PHP's native session machinery.  You should only  need to pass something here if you have your own sessioning  implementation.</span>			</li>
					<li>
				<span class="var-type">str</span>
				<span class="var-name">$consumer_cls</span><span class="var-description">: The name of the class to instantiate  when creating the internal consumer object.  This is used for  testing.</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">&$store</span>			</li>
				</ul>
		
			
	</div>
<a name="methodbegin" id="begin"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">begin</span> (line <span class="line-number">312</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Start the OpenID authentication process. See steps 1-2 in the  overview at the top of this file.</p>
	<ul class="tags">
				<li><span class="field">return:</span> An object  containing the discovered information will be returned, with a  method for building a redirect URL to the server, as described  in step 3 of the overview. This object may also be used to add  extension arguments to the request, using its 'addExtensionArg'  method.</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result"><a href="../OpenID/Auth_OpenID_AuthRequest.html">Auth_OpenID_AuthRequest</a></span>
		<span class="method-name">
			begin
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$user_url</span>, [<span class="var-type">bool</span>&nbsp;<span class="var-name">$anonymous</span> = <span class="var-default">false</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$user_url</span><span class="var-description">: Identity URL given by the user. This  method performs a textual transformation of the URL to try and  make sure it is normalized. For example, a user_url of  example.com will be normalized to http://example.com/  normalizing and resolving any redirects the server might issue.</span>			</li>
					<li>
				<span class="var-type">bool</span>
				<span class="var-name">$anonymous</span><span class="var-description">: True if the OpenID request is to be sent  to the server without any identifier information.  Use this  when you want to transport data but don't want to do OpenID  authentication with identifiers.</span>			</li>
				</ul>
		
			
	</div>
<a name="methodbeginWithoutDiscovery" id="beginWithoutDiscovery"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">beginWithoutDiscovery</span> (line <span class="line-number">372</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Start OpenID verification without doing OpenID server</p>
<p class="description"><p>discovery. This method is used internally by Consumer.begin  after discovery is performed, and exists to provide an  interface for library users needing to perform their own  discovery.</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> An OpenID  authentication request object.</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result"><a href="../OpenID/Auth_OpenID_AuthRequest.html">Auth_OpenID_AuthRequest</a></span>
		<span class="method-name">
			&amp;beginWithoutDiscovery
		</span>
					(<span class="var-type">Auth_OpenID_ServiceEndpoint</span>&nbsp;<span class="var-name">$endpoint</span>, [<span class="var-type">bool</span>&nbsp;<span class="var-name">$anonymous</span> = <span class="var-default">false</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">Auth_OpenID_ServiceEndpoint</span>
				<span class="var-name">$endpoint</span><span class="var-description">: an OpenID service  endpoint descriptor.</span>			</li>
					<li>
				<span class="var-type">bool</span>
				<span class="var-name">$anonymous</span><span class="var-description">: anonymous Set to true if you want to perform OpenID  without identifiers.</span>			</li>
				</ul>
		
			
	</div>
<a name="methodcomplete" id="complete"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">complete</span> (line <span class="line-number">402</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Called to interpret the server's response to an OpenID  request. It is called in step 4 of the flow described in the  consumer overview.</p>
	<ul class="tags">
				<li><span class="field">return:</span> A instance of an  Auth_OpenID_ConsumerResponse subclass. The type of response is  indicated by the status attribute, which will be one of  SUCCESS, CANCEL, FAILURE, or SETUP_NEEDED.</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result"><a href="../OpenID/Auth_OpenID_ConsumerResponse.html">Auth_OpenID_ConsumerResponse</a></span>
		<span class="method-name">
			complete
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$return_to</span>, [<span class="var-type">array</span>&nbsp;<span class="var-name">$query</span> = <span class="var-default">null</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">array</span>
				<span class="var-name">$query</span><span class="var-description">: An array of the query parameters (key =&gt;  value pairs) for this HTTP request.  Defaults to null.  If  null, the GET or POST data are automatically gotten from the  PHP environment.  It is only useful to override $query for  testing.</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$return_to</span>			</li>
				</ul>
		
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Wed, 05 Dec 2007 14:02:11 -0800 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.2</a>
	</p>
	</div></body>
</html>