1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
3
<title>sbuild: sbuild::auth_conv Class Reference</title>
4
<link href="tabs.css" rel="stylesheet" type="text/css">
5
<link href="doxygen.css" rel="stylesheet" type="text/css">
7
<!-- Generated by Doxygen 1.5.9 -->
8
<div class="navigation" id="top">
11
<li><a href="index.html"><span>Main Page</span></a></li>
12
<li><a href="pages.html"><span>Related Pages</span></a></li>
13
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
14
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
15
<li><a href="files.html"><span>Files</span></a></li>
16
<li><a href="dirs.html"><span>Directories</span></a></li>
21
<li><a href="annotated.html"><span>Class List</span></a></li>
22
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
23
<li><a href="functions.html"><span>Class Members</span></a></li>
26
<div class="navpath"><a class="el" href="namespacesbuild.html">sbuild</a>::<a class="el" href="classsbuild_1_1auth__conv.html">auth_conv</a>
29
<div class="contents">
30
<h1>sbuild::auth_conv Class Reference</h1><!-- doxytag: class="sbuild::auth_conv" -->Authentication conversation handler interface.
31
<a href="#_details">More...</a>
33
<code>#include <<a class="el" href="sbuild-auth-conv_8h_source.html">sbuild-auth-conv.h</a>></code>
35
<div class="dynheader">
36
Inheritance diagram for sbuild::auth_conv:</div>
37
<div class="dynsection">
38
<p><center><img src="classsbuild_1_1auth__conv__inherit__graph.png" border="0" usemap="#sbuild_1_1auth__conv__inherit__map" alt="Inheritance graph"></center>
39
<map name="sbuild_1_1auth__conv__inherit__map">
40
<area shape="rect" href="classsbuild_1_1auth__conv__tty.html" title="Authentication conversation handler for terminal devices." alt="" coords="5,83,149,112"></map>
41
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div>
44
<a href="classsbuild_1_1auth__conv-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
46
<tr><td colspan="2"><br><h2>Public Types</h2></td></tr>
47
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef std::vector< <a class="el" href="classsbuild_1_1auth__message.html">auth_message</a> > </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#7dd89895a7f0214f0b82e567d3d235fa">message_list</a></td></tr>
49
<tr><td class="mdescLeft"> </td><td class="mdescRight">A list of messages. <a href="#7dd89895a7f0214f0b82e567d3d235fa"></a><br></td></tr>
50
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
51
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#6271be2f5d6ade0e0d83eb0de66ab84b">auth_conv</a> ()</td></tr>
53
<tr><td class="mdescLeft"> </td><td class="mdescRight">The constructor. <a href="#6271be2f5d6ade0e0d83eb0de66ab84b"></a><br></td></tr>
54
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#621dc0c57149768a2652dfc7d55a7eef">~auth_conv</a> ()</td></tr>
56
<tr><td class="mdescLeft"> </td><td class="mdescRight">The destructor. <a href="#621dc0c57149768a2652dfc7d55a7eef"></a><br></td></tr>
57
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual time_t </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#3b6430fec4d0d6a07eed53267d705cdc">get_warning_timeout</a> ()=0</td></tr>
59
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get the time at which the user will be warned. <a href="#3b6430fec4d0d6a07eed53267d705cdc"></a><br></td></tr>
60
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#b39cfeb91d3e68c380dfe744d320e7d0">set_warning_timeout</a> (time_t timeout)=0</td></tr>
62
<tr><td class="mdescLeft"> </td><td class="mdescRight">Set the time at which the user will be warned. <a href="#b39cfeb91d3e68c380dfe744d320e7d0"></a><br></td></tr>
63
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual time_t </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#61936972df24382d2ee819f17a078ebf">get_fatal_timeout</a> ()=0</td></tr>
65
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get the time at which the conversation will be terminated with an <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>. <a href="#61936972df24382d2ee819f17a078ebf"></a><br></td></tr>
66
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#0de7c8e9493e6b3ed55e0520171c8f1b">set_fatal_timeout</a> (time_t timeout)=0</td></tr>
68
<tr><td class="mdescLeft"> </td><td class="mdescRight">Set the time at which the conversation will be terminated with an <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>. <a href="#0de7c8e9493e6b3ed55e0520171c8f1b"></a><br></td></tr>
69
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classsbuild_1_1auth__conv.html#3fd81782872b31ca5daad9e79e79fef6">conversation</a> (<a class="el" href="classsbuild_1_1auth__conv.html#7dd89895a7f0214f0b82e567d3d235fa">message_list</a> &messages)=0</td></tr>
71
<tr><td class="mdescLeft"> </td><td class="mdescRight">Hold a conversation with the user. <a href="#3fd81782872b31ca5daad9e79e79fef6"></a><br></td></tr>
73
<hr><a name="_details"></a><h2>Detailed Description</h2>
74
Authentication conversation handler interface.
76
This interface should be implemented by objects which handle interaction with the user during authentication.<p>
77
This is a wrapper around the struct pam_conv PAM conversation interface, and is used by <a class="el" href="classsbuild_1_1auth.html" title="Authentication handler.">auth</a> when interacting with the user during authentication.<p>
78
A simple implementation is provided in the form of <a class="el" href="classsbuild_1_1auth__conv__tty.html" title="Authentication conversation handler for terminal devices.">auth_conv_tty</a>. However, more complex implementations might hook into the event loop of a GUI widget system, for example.<p>
79
The interface allows the setting of optional warning timeout and fatal timeout values, which should default to 0 (not enabled). This is an absolute time after which a warning is displayed or the conversation ends with an <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>. <hr><h2>Member Typedef Documentation</h2>
80
<a class="anchor" name="7dd89895a7f0214f0b82e567d3d235fa"></a><!-- doxytag: member="sbuild::auth_conv::message_list" ref="7dd89895a7f0214f0b82e567d3d235fa" args="" -->
82
<div class="memproto">
83
<table class="memname">
85
<td class="memname">typedef std::vector<<a class="el" href="classsbuild_1_1auth__message.html">auth_message</a>> <a class="el" href="classsbuild_1_1auth__conv.html#7dd89895a7f0214f0b82e567d3d235fa">sbuild::auth_conv::message_list</a> </td>
97
<hr><h2>Constructor & Destructor Documentation</h2>
98
<a class="anchor" name="6271be2f5d6ade0e0d83eb0de66ab84b"></a><!-- doxytag: member="sbuild::auth_conv::auth_conv" ref="6271be2f5d6ade0e0d83eb0de66ab84b" args="()" -->
100
<div class="memproto">
101
<table class="memname">
103
<td class="memname">auth_conv::auth_conv </td>
105
<td class="paramname"> </td>
106
<td> ) </td>
119
<a class="anchor" name="621dc0c57149768a2652dfc7d55a7eef"></a><!-- doxytag: member="sbuild::auth_conv::~auth_conv" ref="621dc0c57149768a2652dfc7d55a7eef" args="()" -->
120
<div class="memitem">
121
<div class="memproto">
122
<table class="memname">
124
<td class="memname">auth_conv::~auth_conv </td>
126
<td class="paramname"> </td>
127
<td> ) </td>
128
<td><code> [virtual]</code></td>
140
<hr><h2>Member Function Documentation</h2>
141
<a class="anchor" name="3fd81782872b31ca5daad9e79e79fef6"></a><!-- doxytag: member="sbuild::auth_conv::conversation" ref="3fd81782872b31ca5daad9e79e79fef6" args="(message_list &messages)=0" -->
142
<div class="memitem">
143
<div class="memproto">
144
<table class="memname">
146
<td class="memname">virtual void sbuild::auth_conv::conversation </td>
148
<td class="paramtype"><a class="el" href="classsbuild_1_1auth__conv.html#7dd89895a7f0214f0b82e567d3d235fa">message_list</a> & </td>
149
<td class="paramname"> <em>messages</em> </td>
150
<td> ) </td>
151
<td><code> [pure virtual]</code></td>
158
Hold a conversation with the user.
160
Each of the messages detailed in messages should be displayed to the user, asking for input where required. The type of message is indicated in the <a class="el" href="classsbuild_1_1auth__message.html#eccbf2dfcab41b6a2a8d78d6e08e7ff9" title="The type of message.">auth_message::type</a> field of the <a class="el" href="classsbuild_1_1auth__message.html" title="Authentication messages.">auth_message</a>. The <a class="el" href="classsbuild_1_1auth__message.html#ca3c58ab40f37157eed601df1f30208a" title="The user's response (if any).">auth_message::response</a> field of the <a class="el" href="classsbuild_1_1auth__message.html" title="Authentication messages.">auth_message</a> should be filled in if input is required.<p>
161
On <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>, an exception will be thrown.<p>
162
<dl compact><dt><b>Parameters:</b></dt><dd>
163
<table border="0" cellspacing="2" cellpadding="0">
164
<tr><td valign="top"></td><td valign="top"><em>messages</em> </td><td>the messages to display to the user, and responses to return to the caller. </td></tr>
168
<p>Implemented in <a class="el" href="classsbuild_1_1auth__conv__tty.html#a42c43aee20241e9015a0e331e3c4999">sbuild::auth_conv_tty</a>.</p>
172
<a class="anchor" name="61936972df24382d2ee819f17a078ebf"></a><!-- doxytag: member="sbuild::auth_conv::get_fatal_timeout" ref="61936972df24382d2ee819f17a078ebf" args="()=0" -->
173
<div class="memitem">
174
<div class="memproto">
175
<table class="memname">
177
<td class="memname">virtual time_t sbuild::auth_conv::get_fatal_timeout </td>
179
<td class="paramname"> </td>
180
<td> ) </td>
181
<td><code> [pure virtual]</code></td>
188
Get the time at which the conversation will be terminated with an <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>.
190
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the time. </dd></dl>
192
<p>Implemented in <a class="el" href="classsbuild_1_1auth__conv__tty.html#8e1948e1c062e033b66ba14c52c06b6f">sbuild::auth_conv_tty</a>.</p>
196
<a class="anchor" name="3b6430fec4d0d6a07eed53267d705cdc"></a><!-- doxytag: member="sbuild::auth_conv::get_warning_timeout" ref="3b6430fec4d0d6a07eed53267d705cdc" args="()=0" -->
197
<div class="memitem">
198
<div class="memproto">
199
<table class="memname">
201
<td class="memname">virtual time_t sbuild::auth_conv::get_warning_timeout </td>
203
<td class="paramname"> </td>
204
<td> ) </td>
205
<td><code> [pure virtual]</code></td>
212
Get the time at which the user will be warned.
214
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the time. </dd></dl>
216
<p>Implemented in <a class="el" href="classsbuild_1_1auth__conv__tty.html#b637493bac92c8db9e7e22012be53d3a">sbuild::auth_conv_tty</a>.</p>
220
<a class="anchor" name="0de7c8e9493e6b3ed55e0520171c8f1b"></a><!-- doxytag: member="sbuild::auth_conv::set_fatal_timeout" ref="0de7c8e9493e6b3ed55e0520171c8f1b" args="(time_t timeout)=0" -->
221
<div class="memitem">
222
<div class="memproto">
223
<table class="memname">
225
<td class="memname">virtual void sbuild::auth_conv::set_fatal_timeout </td>
227
<td class="paramtype">time_t </td>
228
<td class="paramname"> <em>timeout</em> </td>
229
<td> ) </td>
230
<td><code> [pure virtual]</code></td>
237
Set the time at which the conversation will be terminated with an <a class="el" href="classsbuild_1_1error.html" title="Error exception class.">error</a>.
239
<dl compact><dt><b>Parameters:</b></dt><dd>
240
<table border="0" cellspacing="2" cellpadding="0">
241
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>the time to set. </td></tr>
245
<p>Implemented in <a class="el" href="classsbuild_1_1auth__conv__tty.html#7ca62f5f7337cf18d12fb3c43014ffbc">sbuild::auth_conv_tty</a>.</p>
249
<a class="anchor" name="b39cfeb91d3e68c380dfe744d320e7d0"></a><!-- doxytag: member="sbuild::auth_conv::set_warning_timeout" ref="b39cfeb91d3e68c380dfe744d320e7d0" args="(time_t timeout)=0" -->
250
<div class="memitem">
251
<div class="memproto">
252
<table class="memname">
254
<td class="memname">virtual void sbuild::auth_conv::set_warning_timeout </td>
256
<td class="paramtype">time_t </td>
257
<td class="paramname"> <em>timeout</em> </td>
258
<td> ) </td>
259
<td><code> [pure virtual]</code></td>
266
Set the time at which the user will be warned.
268
<dl compact><dt><b>Parameters:</b></dt><dd>
269
<table border="0" cellspacing="2" cellpadding="0">
270
<tr><td valign="top"></td><td valign="top"><em>timeout</em> </td><td>the time to set. </td></tr>
274
<p>Implemented in <a class="el" href="classsbuild_1_1auth__conv__tty.html#f913e05422e6e92fb3531bd55e3d39af">sbuild::auth_conv_tty</a>.</p>
278
<hr>The documentation for this class was generated from the following files:<ul>
279
<li>sbuild/<a class="el" href="sbuild-auth-conv_8h_source.html">sbuild-auth-conv.h</a><li>sbuild/<a class="el" href="sbuild-auth-conv_8cc.html">sbuild-auth-conv.cc</a></ul>
281
<hr size="1"><address style="text-align: right;"><small>Generated on Sun May 17 18:39:14 2009 for sbuild by
282
<a href="http://www.doxygen.org/index.html">
283
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.9 </small></address>