(file) Return to Authenticator.h CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Security / Authentication

 1 karl  1.7 //%2003////////////////////////////////////////////////////////////////////////
 2 mike  1.2 //
 3 karl  1.7 // Copyright (c) 2000, 2001, 2002  BMC Software, Hewlett-Packard Development
 4           // Company, L. P., IBM Corp., The Open Group, Tivoli Systems.
 5           // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.;
 6           // IBM Corp.; EMC Corporation, The Open Group.
 7 mike  1.2 //
 8 kumpf 1.5 // Permission is hereby granted, free of charge, to any person obtaining a copy
 9           // of this software and associated documentation files (the "Software"), to
10           // deal in the Software without restriction, including without limitation the
11           // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
12           // sell copies of the Software, and to permit persons to whom the Software is
13           // furnished to do so, subject to the following conditions:
14           // 
15           // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
16           // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
17           // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
18           // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
19           // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
20           // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
21           // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22           // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23 mike  1.2 //
24           //==============================================================================
25           //
26           // Author: Bapu Patil, Hewlett-Packard Company (bapu_patil@hp.com)
27           //
28           // Modified By:
29           //              Nag Boranna, Hewlett-Packard Company(nagaraja_boranna@hp.com)
30           //
31           //%/////////////////////////////////////////////////////////////////////////////
32           
33           #ifndef Pegasus_Authenticator_h
34           #define Pegasus_Authenticator_h
35           
36           #include <Pegasus/Common/Config.h>
37           #include <Pegasus/Common/String.h>
38           #include <Pegasus/Common/AuthenticationInfo.h>
39 kumpf 1.4 #include <Pegasus/Common/AuthenticationInfoRep.h>
40           
41 chuck 1.6 #include <Pegasus/Security/Authentication/Linkage.h>
42 mike  1.2 
43           
44           PEGASUS_NAMESPACE_BEGIN
45           
46 kumpf 1.4 /** This is an abstract class that the authentication handlers will extend and
47               provide the implementation.
48 mike  1.2 */
49           class PEGASUS_SECURITY_LINKAGE Authenticator
50           {
51           public:
52           
53               /** Constructors  */
54               Authenticator() { };
55           
56               /** Destructor  */
57               virtual ~Authenticator() { };
58           
59 kumpf 1.4     /** Verify the authentication of the user passed in the HTTP authorization header.
60                   @param authHeader String containing the Authorization header
61                   @param authInfo Reference to AuthenticationInfo object
62                   @return true on successful authentication, false otherwise
63 mike  1.2     */
64 kumpf 1.3     virtual Boolean authenticate(
65                   const String& authHeader, 
66                   AuthenticationInfo* authInfo) = 0;
67 mike  1.2 
68 kumpf 1.4     /** Construct and return the Basic authentication challenge header
69                   @param authType String containing the authentication type
70                   @param userName String containing the user name
71                   @param authInfo Reference to AuthenticationInfo object
72                   @return A string containing the authentication challenge header.
73 mike  1.2     */
74               virtual String getAuthResponseHeader(
75 kumpf 1.4         const String& authType = String::EMPTY,
76                   const String& userName = String::EMPTY,
77 kumpf 1.3         AuthenticationInfo* authInfo = 0) = 0;
78 mike  1.2 };
79           
80           PEGASUS_NAMESPACE_END
81           
82           #endif   /* Pegasus_Authenticator_h*/

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2