pion::user Class Reference

#include <user.hpp>

List of all members.

Public Member Functions

 user (std::string const &username)
 construct a new user object
 user (std::string const &username, std::string const &password)
 construct a new user object
virtual ~user ()
 virtual destructor
std::string const & get_username () const
 returns user name as a string
std::string const & get_password () const
 returns password for the user (encrypted if SSL is enabled)
virtual bool match_password (const std::string &password) const
virtual void set_password (const std::string &password)
 sets password credentials for given user
virtual void set_password_hash (const std::string &password_hash)
 sets encrypted password credentials for given user

Protected Attributes

const std::string m_username
 username string
std::string m_password
 password string (actual contents depends on implementation)
unsigned char m_password_hash [SHA_DIGEST_LENGTH]
 SHA1 hash of the password.

Detailed Description

user: base class to store user credentials

Definition at line 39 of file user.hpp.


Member Function Documentation

virtual bool pion::user::match_password ( const std::string &  password  )  const [inline, virtual]

matches password credential for given user

Parameters:
password password credentials

Definition at line 70 of file user.hpp.

References m_password, and m_password_hash.


The documentation for this class was generated from the following file:

Generated on 16 Sep 2013 for pion by  doxygen 1.6.1