Public Member Functions | Static Public Attributes | Protected Attributes | List of all members
AppSecInc::Databases::MSSQL::MSSQLConnectionInfo Class Reference

An authenticated Microsoft SQL Server connection info. More...

#include <MSSQLConnectionInfo.h>

Inheritance diagram for AppSecInc::Databases::MSSQL::MSSQLConnectionInfo:
AppSecInc::Databases::ODBC::ODBCConnectionInfo

Public Member Functions

const std::wstring & GetIPAddress () const
 get the database ip address or host name More...
 
void SetIPAddress (const std::wstring &ipaddress)
 set the database ip address or host name More...
 
int GetPort () const
 get the database port number More...
 
void SetPort (int port)
 set the database port number More...
 
AppSecInc::Databases::ODBC::ODBCConnectionProtocol GetProtocol () const
 get the connection protocol: TCP/IP or named pipes More...
 
void SetProtocol (AppSecInc::Databases::ODBC::ODBCConnectionProtocol protocol)
 set the connection protocol More...
 
bool GetTrustedAuth () const
 get whether to use trusted auth More...
 
void SetTrustedAuth (bool value)
 set whether to use trusted auth More...
 
const std::wstring & GetUsername () const
 get username More...
 
void SetUsername (const std::wstring &username)
 set username More...
 
const std::wstring & GetPassword () const
 get password More...
 
void SetPassword (const std::wstring &password)
 set password More...
 
const std::wstring & GetDatabase () const
 get default database name More...
 
void SetDatabase (const std::wstring &database)
 set default database name More...
 
const std::wstring & GetAppName () const
 get application name More...
 
void SetAppName (const std::wstring &value)
 set application name More...
 
const std::wstring & GetInstanceName () const
 get the database instance name More...
 
void SetInstanceName (const std::wstring &instancename)
 set the database instance name More...
 
const std::wstring & GetNamedPipeValue () const
 get the instance named pipe value More...
 
void SetNamedPipeValue (const std::wstring &namedpipe)
 set the instance named pipe value More...
 
 MSSQLConnectionInfo (const MSSQLConnectionInfo &)
 constructors/destructors More...
 
 MSSQLConnectionInfo (const std::wstring &ipaddress=DEFAULT_IPADDRESS, int port=DEFAULT_PORT)
 
 ~MSSQLConnectionInfo ()
 
void operator= (const MSSQLConnectionInfo &)
 
std::wstring GetConnectionString () const
 get the connection string More...
 
- Public Member Functions inherited from AppSecInc::Databases::ODBC::ODBCConnectionInfo
 ODBCConnectionInfo ()
 
virtual ~ODBCConnectionInfo ()
 

Static Public Attributes

static LPCWSTR DEFAULT_IPADDRESS = L"localhost"
 the default ip address More...
 
static const int INVALID_PORT = -1
 an invalid port More...
 
static const int DEFAULT_PORT = 1433
 the default port More...
 
static LPCWSTR DefaultInstanceName = L"MSSQLSERVER"
 the default instance name; MSSQLSERVER More...
 

Protected Attributes

std::wstring _ipaddress
 the database ip address More...
 
int _port
 the database port More...
 
AppSecInc::Databases::ODBC::ODBCConnectionProtocol _protocol
 the connection protocol to use; default is unspecified More...
 
std::wstring _instancename
 the name of the database instance More...
 
bool _trusted_auth
 use trusted auth (windows auth) More...
 
std::wstring _username
 username More...
 
std::wstring _password
 password More...
 
std::wstring _database
 database name More...
 
std::wstring _appname
 application name connecting to the remote database More...
 
std::wstring _namedpipe
 named pipe for the database instance More...
 

Detailed Description

An authenticated Microsoft SQL Server connection info.

Constructor & Destructor Documentation

MSSQLConnectionInfo::MSSQLConnectionInfo ( const MSSQLConnectionInfo info)

constructors/destructors

MSSQLConnectionInfo::MSSQLConnectionInfo ( const std::wstring &  ipaddress = DEFAULT_IPADDRESS,
int  port = DEFAULT_PORT 
)
MSSQLConnectionInfo::~MSSQLConnectionInfo ( )

Member Function Documentation

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetAppName ( ) const
inline

get application name

std::wstring MSSQLConnectionInfo::GetConnectionString ( ) const
virtual

get the connection string

Implements AppSecInc::Databases::ODBC::ODBCConnectionInfo.

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetDatabase ( ) const
inline

get default database name

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetInstanceName ( ) const
inline

get the database instance name

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetIPAddress ( ) const
inline

get the database ip address or host name

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetNamedPipeValue ( ) const
inline

get the instance named pipe value

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetPassword ( ) const
inline

get password

int AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetPort ( ) const
inline

get the database port number

AppSecInc::Databases::ODBC::ODBCConnectionProtocol AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetProtocol ( ) const
inline

get the connection protocol: TCP/IP or named pipes

bool AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetTrustedAuth ( ) const
inline

get whether to use trusted auth

const std::wstring& AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::GetUsername ( ) const
inline

get username

void MSSQLConnectionInfo::operator= ( const MSSQLConnectionInfo info)
void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetAppName ( const std::wstring &  value)
inline

set application name

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetDatabase ( const std::wstring &  database)
inline

set default database name

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetInstanceName ( const std::wstring &  instancename)
inline

set the database instance name

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetIPAddress ( const std::wstring &  ipaddress)
inline

set the database ip address or host name

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetNamedPipeValue ( const std::wstring &  namedpipe)
inline

set the instance named pipe value

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetPassword ( const std::wstring &  password)
inline

set password

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetPort ( int  port)
inline

set the database port number

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetProtocol ( AppSecInc::Databases::ODBC::ODBCConnectionProtocol  protocol)
inline

set the connection protocol

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetTrustedAuth ( bool  value)
inline

set whether to use trusted auth

void AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::SetUsername ( const std::wstring &  username)
inline

set username

Member Data Documentation

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_appname
protected

application name connecting to the remote database

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_database
protected

database name

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_instancename
protected

the name of the database instance

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_ipaddress
protected

the database ip address

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_namedpipe
protected

named pipe for the database instance

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_password
protected

password

int AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_port
protected

the database port

AppSecInc::Databases::ODBC::ODBCConnectionProtocol AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_protocol
protected

the connection protocol to use; default is unspecified

bool AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_trusted_auth
protected

use trusted auth (windows auth)

std::wstring AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::_username
protected

username

LPCWSTR MSSQLConnectionInfo::DEFAULT_IPADDRESS = L"localhost"
static

the default ip address

const int AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::DEFAULT_PORT = 1433
static

the default port

LPCWSTR MSSQLConnectionInfo::DefaultInstanceName = L"MSSQLSERVER"
static

the default instance name; MSSQLSERVER

const int AppSecInc::Databases::MSSQL::MSSQLConnectionInfo::INVALID_PORT = -1
static

an invalid port


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


© Application Security Inc. - All Rights Reserved http://msiext.codeplex.com