~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/plugin/authentication.h

  • Committer: Brian Aker
  • Date: 2010-10-27 21:00:49 UTC
  • mto: This revision was merged to the branch mainline in revision 1886.
  • Revision ID: brian@tangent.org-20101027210049-zfpgx2cfbrh8maq9
A couple of fixes to documentation.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
 *
4
4
 *  Definitions required for Authentication plugin
5
5
 *
6
 
 *  Copyright (C) 2008 Sun Microsystems, Inc.
 
6
 *  Copyright (C) 2008 Sun Microsystems
7
7
 *
8
8
 *  This program is free software; you can redistribute it and/or modify
9
9
 *  it under the terms of the GNU General Public License as published by
26
26
 
27
27
#include "drizzled/plugin.h"
28
28
#include "drizzled/plugin/plugin.h"
29
 
#include "drizzled/identifier.h"
30
 
 
31
 
#include "drizzled/visibility.h"
32
29
 
33
30
namespace drizzled
34
31
{
35
 
 
36
 
namespace identifier {
37
 
class User;
38
 
 
32
class SecurityContext;
39
33
 
40
34
namespace plugin
41
35
{
42
36
 
43
 
class DRIZZLED_API Authentication : public Plugin
 
37
class Authentication : public Plugin
44
38
{
45
39
  Authentication();
46
40
  Authentication(const Authentication &);
51
45
  {}
52
46
  virtual ~Authentication() {}
53
47
 
54
 
  virtual bool authenticate(const identifier::User &sctx,
 
48
  virtual bool authenticate(const SecurityContext &sctx,
55
49
                            const std::string &passwd)= 0;
56
50
 
57
51
  static bool addPlugin(plugin::Authentication *auth);
58
52
  static void removePlugin(plugin::Authentication *auth);
59
 
  static bool isAuthenticated(drizzled::identifier::User::const_shared_ptr sctx,
 
53
  static bool isAuthenticated(const SecurityContext &sctx,
60
54
                              const std::string &password);
61
55
};
62
56