#include <RTSPServer.hh>
Collaboration diagram for UserAuthenticationDatabase:

Public Member Functions | |
| UserAuthenticationDatabase (char const *realm=NULL, Boolean passwordsAreMD5=False) | |
| virtual | ~UserAuthenticationDatabase () |
| virtual void | addUserRecord (char const *username, char const *password) |
| virtual void | removeUserRecord (char const *username) |
| virtual char const * | lookupPassword (char const *username) |
| char const * | realm () |
| Boolean | passwordsAreMD5 () |
Protected Attributes | |
| HashTable * | fTable |
| char * | fRealm |
| Boolean | fPasswordsAreMD5 |
Definition at line 36 of file RTSPServer.hh.
| UserAuthenticationDatabase::UserAuthenticationDatabase | ( | char const * | realm = NULL, |
|
| Boolean | passwordsAreMD5 = False | |||
| ) |
Definition at line 1884 of file RTSPServer.cpp.
01886 : fTable(HashTable::create(STRING_HASH_KEYS)), 01887 fRealm(strDup(realm == NULL ? "LIVE555 Streaming Media" : realm)), 01888 fPasswordsAreMD5(passwordsAreMD5) { 01889 }
| UserAuthenticationDatabase::~UserAuthenticationDatabase | ( | ) | [virtual] |
Definition at line 1891 of file RTSPServer.cpp.
References fRealm, fTable, NULL, password, and HashTable::RemoveNext().
01891 { 01892 delete[] fRealm; 01893 01894 // Delete the allocated 'password' strings that we stored in the table, and then the table itself: 01895 char* password; 01896 while ((password = (char*)fTable->RemoveNext()) != NULL) { 01897 delete[] password; 01898 } 01899 delete fTable; 01900 }
| void UserAuthenticationDatabase::addUserRecord | ( | char const * | username, | |
| char const * | password | |||
| ) | [virtual] |
| void UserAuthenticationDatabase::removeUserRecord | ( | char const * | username | ) | [virtual] |
Definition at line 1907 of file RTSPServer.cpp.
References fTable, HashTable::Lookup(), password, and HashTable::Remove().
01907 { 01908 char* password = (char*)(fTable->Lookup(username)); 01909 fTable->Remove(username); 01910 delete[] password; 01911 }
| char const * UserAuthenticationDatabase::lookupPassword | ( | char const * | username | ) | [virtual] |
| char const* UserAuthenticationDatabase::realm | ( | ) | [inline] |
| Boolean UserAuthenticationDatabase::passwordsAreMD5 | ( | ) | [inline] |
Definition at line 52 of file RTSPServer.hh.
References fPasswordsAreMD5.
00052 { return fPasswordsAreMD5; }
HashTable* UserAuthenticationDatabase::fTable [protected] |
Definition at line 55 of file RTSPServer.hh.
Referenced by addUserRecord(), lookupPassword(), removeUserRecord(), and ~UserAuthenticationDatabase().
char* UserAuthenticationDatabase::fRealm [protected] |
Definition at line 56 of file RTSPServer.hh.
Referenced by realm(), and ~UserAuthenticationDatabase().
Boolean UserAuthenticationDatabase::fPasswordsAreMD5 [protected] |
1.5.2