OPAL  Version 3.14.3
H323GatekeeperServer Class Reference

#include <gkserver.h>

Inheritance diagram for H323GatekeeperServer:
Collaboration diagram for H323GatekeeperServer:

Data Structures

class  StringMap
 

Public Member Functions

WORD GetDefaultUdpPort ()
 
PSafePtr< H323RegisteredEndPointFindDestinationEndPoint (const OpalGloballyUniqueID &id, H323GatekeeperCall::Direction direction)
 
void RemoveAlias (H323RegisteredEndPoint &ep, const PString &alias)
 
virtual PBoolean OnSendDescriptorForEndpoint (H323RegisteredEndPoint &, H225_ArrayOf_AliasAddress &, H225_EndpointType &, H225_ArrayOf_AliasAddress &)
 
virtual PBoolean AllowDuplicateAlias (const H225_ArrayOf_AliasAddress &)
 
virtual PString AllocateAlias (H225_RegistrationRequest &rrq)
 
virtual PBoolean OnSendFeatureSet (H460_MessageType pduType, H225_FeatureSet &features) const
 
virtual void OnReceiveFeatureSet (H460_MessageType pduType, const H225_FeatureSet &features) const
 
Construction
 H323GatekeeperServer (H323EndPoint &endpoint)
 
 ~H323GatekeeperServer ()
 
Protocol Handler Operations
virtual H323TransactorCreateListener (H323Transport *transport)
 
EndPoint Operations
virtual
H323GatekeeperRequest::Response 
OnDiscovery (H323GatekeeperGRQ &request)
 
virtual
H323GatekeeperRequest::Response 
OnRegistration (H323GatekeeperRRQ &request)
 
virtual
H323GatekeeperRequest::Response 
OnUnregistration (H323GatekeeperURQ &request)
 
virtual
H323GatekeeperRequest::Response 
OnInfoResponse (H323GatekeeperIRR &request)
 
virtual void AddEndPoint (H323RegisteredEndPoint *ep)
 
virtual PBoolean RemoveEndPoint (H323RegisteredEndPoint *ep)
 
virtual H323RegisteredEndPointCreateRegisteredEndPoint (H323GatekeeperRequest &request)
 
virtual PString CreateEndPointIdentifier ()
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointByIdentifier (const PString &identifier, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointBySignalAddresses (const H225_ArrayOf_TransportAddress &addresses, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointBySignalAddress (const H323TransportAddress &address, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointByAliasAddress (const H225_AliasAddress &alias, PSafetyMode mode=PSafeReadWrite)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointByAliasString (const PString &alias, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointByPartialAlias (const PString &alias, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323RegisteredEndPoint
FindEndPointByPrefixString (const PString &prefix, PSafetyMode mode=PSafeReference)
 
PSafePtr< H323RegisteredEndPointGetFirstEndPoint (PSafetyMode mode=PSafeReference)
 
Call Operations
virtual
H323GatekeeperRequest::Response 
OnAdmission (H323GatekeeperARQ &request)
 
virtual
H323GatekeeperRequest::Response 
OnDisengage (H323GatekeeperDRQ &request)
 
virtual
H323GatekeeperRequest::Response 
OnBandwidth (H323GatekeeperBRQ &request)
 
virtual H323GatekeeperCallCreateCall (const OpalGloballyUniqueID &callIdentifier, H323GatekeeperCall::Direction direction)
 
virtual void AddCall (H323GatekeeperCall *)
 
virtual void RemoveCall (H323GatekeeperCall *call)
 
virtual PSafePtr
< H323GatekeeperCall
FindCall (const PString &description, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323GatekeeperCall
FindCall (const OpalGloballyUniqueID &callIdentifier, PBoolean answeringCall, PSafetyMode mode=PSafeReference)
 
virtual PSafePtr
< H323GatekeeperCall
FindCall (const OpalGloballyUniqueID &callIdentifier, H323GatekeeperCall::Direction direction, PSafetyMode mode=PSafeReference)
 
PSafePtr< H323GatekeeperCallGetFirstCall (PSafetyMode mode=PSafeReference)
 
Routing operations
virtual
H323GatekeeperRequest::Response 
OnLocation (H323GatekeeperLRQ &request)
 
virtual PBoolean TranslateAliasAddress (const H225_AliasAddress &alias, H225_ArrayOf_AliasAddress &aliases, H323TransportAddress &address, PBoolean &isGkRouted, H323GatekeeperCall *call)
 
virtual PBoolean TranslateAliasAddressToSignalAddress (const H225_AliasAddress &alias, H323TransportAddress &address)
 
Policy operations
virtual PBoolean CheckSignalAddressPolicy (const H323RegisteredEndPoint &ep, const H225_AdmissionRequest &arq, const H323TransportAddress &address)
 
virtual PBoolean CheckAliasAddressPolicy (const H323RegisteredEndPoint &ep, const H225_AdmissionRequest &arq, const H225_AliasAddress &alias)
 
virtual PBoolean CheckAliasStringPolicy (const H323RegisteredEndPoint &ep, const H225_AdmissionRequest &arq, const PString &alias)
 
virtual unsigned AllocateBandwidth (unsigned newBandwidth, unsigned oldBandwidth=0)
 
Security and authentication functions
virtual PBoolean GetAdmissionRequestAuthentication (H323GatekeeperARQ &info, H235Authenticators &authenticators)
 
virtual PBoolean GetUsersPassword (const PString &alias, PString &password, H323RegisteredEndPoint &registeredEndpoint) const
 
virtual PBoolean GetUsersPassword (const PString &alias, PString &password) const
 
virtual void SetUsersPassword (const PString &alias, const PString &password)
 
virtual void ClearPasswords ()
 
H.323 Annex G Peer Element support
H323PeerElementGetPeerElement () const
 
void SetPeerElement (H323PeerElement *newPeerElement)
 
void CreatePeerElement (const H323TransportAddress &h501Interface)
 
bool OpenPeerElement (const H323TransportAddress &remotePeer, bool append=false, bool keepTrying=true)
 
Access functions
const PString & GetGatekeeperIdentifier () const
 
void SetGatekeeperIdentifier (const PString &id, bool adjustListeners=true)
 
unsigned GetAvailableBandwidth () const
 
void SetAvailableBandwidth (unsigned bps100)
 
unsigned GetUsedBandwidth () const
 
unsigned GetDefaultBandwidth () const
 
void SetDefaultBandwidth (unsigned bw)
 
unsigned GetMaximumBandwidth () const
 
void SetMaximumBandwidth (unsigned bw)
 
unsigned GetTimeToLive () const
 
void SetTimeToLive (unsigned seconds)
 
unsigned GetInfoResponseRate () const
 
void SetInfoResponseRate (unsigned seconds)
 
bool GetOverwriteOnSameSignalAddress () const
 Allow new registration to gatekeeper on a specific signal address to override previous registration. More...
 
void SetOverwriteOnSameSignalAddress (bool v)
 
unsigned GetMinAliasToAllocate () const
 Minimum value for aliases gatekeeper will allocate when endpoint does not provide one, 0 disables. More...
 
void SetMinAliasToAllocate (unsigned v)
 
unsigned GetMaxAliasToAllocate () const
 Maximum value for aliases gatekeeper will allocate when endpoint does not provide one, 0 disables. More...
 
void SetMaxAliasToAllocate (unsigned v)
 
bool GetCanHaveDuplicateAlias () const
 Different endpoint can register with gatekeeper the same alias name as another endpoint. More...
 
void SetCanHaveDuplicateAlias (bool v)
 
bool GetCanHaveDuplicatePrefix () const
 Gateways may register duplicate prefix E.164 numbers. More...
 
void SetCanHaveDuplicatePrefix (bool v)
 
bool GetCanOnlyCallRegisteredEP () const
 Gatekeeper will only allow EP to call another endpoint registered localy. More...
 
void SetCanOnlyCallRegisteredEP (bool v)
 
bool GetCanOnlyAnswerRegisteredEP () const
 Gatekeeper will only allow endpoint to answer another endpoint registered localy. More...
 
void SetCanOnlyAnswerRegisteredEP (bool v)
 
bool GetAnswerCallPreGrantedARQ () const
 Gatekeeper pre-grants all incoming calls to endpoint. More...
 
void SetAnswerCallPreGrantedARQ (bool v)
 
bool GetMakeCallPreGrantedARQ () const
 Gatekeeper pre-grants all outgoing calls from endpoint. More...
 
void SetMakeCallPreGrantedARQ (bool v)
 
bool GetAliasCanBeHostName () const
 Gatekeeper allows endpoint to simply register its host name/IP address. More...
 
void SetAliasCanBeHostName (bool v)
 
bool GetDisengageOnHearbeatFail () const
 Hang up call if heartbeat (IRR) fails. More...
 
void SetDisengageOnHearbeatFail (bool v)
 
bool IsGatekeeperRouted () const
 
void SetGatekeeperRouted (bool is)
 
bool IsRequiredH235 () const
 
void SetRequiredH235 (bool req)
 
unsigned GetActiveRegistrations () const
 
unsigned GetPeakRegistrations () const
 
unsigned GetTotalRegistrations () const
 
unsigned GetRejectedRegistrations () const
 
unsigned GetActiveCalls () const
 
unsigned GetPeakCalls () const
 
unsigned GetTotalCalls () const
 
unsigned GetRejectedCalls () const
 
- Public Member Functions inherited from H323TransactionServer
 H323TransactionServer (H323EndPoint &endpoint)
 
 ~H323TransactionServer ()
 
H323EndPointGetOwnerEndPoint () const
 
PBoolean AddListeners (const H323TransportAddressArray &ifaces)
 
PBoolean AddListener (const H323TransportAddress &interfaceName)
 
PBoolean AddListener (H323Transport *transport)
 
PBoolean AddListener (H323Transactor *listener)
 
PBoolean RemoveListener (H323Transactor *listener)
 
PBoolean SetUpCallSignalAddresses (H225_ArrayOf_TransportAddress &addresses)
 

Protected Member Functions

 PDECLARE_NOTIFIER (PThread, H323GatekeeperServer, MonitorMain)
 
 PLIST (ListenerList, H323GatekeeperListener)
 
 P_REMOVE_VIRTUAL (H323RegisteredEndPoint *, CreateRegisteredEndPoint(H323GatekeeperRRQ &), 0)
 
- Protected Member Functions inherited from H323TransactionServer
 PLIST (ListenerList, H323Transactor)
 

Protected Attributes

PString m_gatekeeperIdentifier
 
unsigned m_totalBandwidth
 
unsigned m_usedBandwidth
 
unsigned m_defaultBandwidth
 
unsigned m_maximumBandwidth
 
unsigned m_defaultTimeToLive
 
unsigned m_defaultInfoResponseRate
 
bool m_overwriteOnSameSignalAddress
 
unsigned m_minAliasToAllocate
 
unsigned m_maxAliasToAllocate
 
unsigned m_aliasToAllocate
 
bool m_canHaveDuplicateAlias
 
bool m_canHaveDuplicatePrefix
 
bool m_canOnlyCallRegisteredEP
 
bool m_canOnlyAnswerRegisteredEP
 
bool m_answerCallPreGrantedARQ
 
bool m_makeCallPreGrantedARQ
 
bool m_isGatekeeperRouted
 
bool m_aliasCanBeHostName
 
bool m_requireH235
 
bool m_disengageOnHearbeatFail
 
PStringToString m_passwords
 
time_t m_identifierBase
 
unsigned m_nextIdentifier
 
PThread * m_monitorThread
 
PSyncPoint m_monitorExit
 
ListenerList m_listeners
 
H323PeerElementm_peerElement
 
PSafeDictionary
< H225_AliasAddress,
H323RegisteredEndPoint
m_discoveredEndpoints
 
PSafeDictionary< PString,
H323RegisteredEndPoint
m_byIdentifier
 
PSortedStringList m_byAddress
 
PSortedStringList m_byAlias
 
PSortedStringList m_byVoicePrefix
 
PSafeSortedList
< H323GatekeeperCall
m_activeCalls
 
PINDEX m_peakRegistrations
 
PINDEX m_totalRegistrations
 
PAtomicInteger m_rejectedRegistrations
 
PINDEX m_peakCalls
 
PINDEX m_totalCalls
 
PAtomicInteger m_rejectedCalls
 
- Protected Attributes inherited from H323TransactionServer
H323EndPointownerEndPoint
 
PThread * monitorThread
 
PSyncPoint monitorExit
 
PMutex mutex
 
ListenerList listeners
 

Friends

class H323GatekeeperRRQ
 
class H323GatekeeperARQ
 

Detailed Description

This class implements a basic gatekeeper server functionality. An instance of this class contains all of the state information and operations for a gatekeeper. Multiple gatekeeper listeners may be using this class to link individual UDP (or other protocol) packets from various sources (interfaces etc) into a single instance.

There is typically only one instance of this class, though it is not limited to that. An application would also quite likely descend from this class and override call back functions to implement more complex policy.

Constructor & Destructor Documentation

H323GatekeeperServer::H323GatekeeperServer ( H323EndPoint endpoint)

Create a new gatekeeper.

H323GatekeeperServer::~H323GatekeeperServer ( )

Destroy gatekeeper.

Member Function Documentation

virtual void H323GatekeeperServer::AddCall ( H323GatekeeperCall )
inlinevirtual

Called whenever a new call is started

virtual void H323GatekeeperServer::AddEndPoint ( H323RegisteredEndPoint ep)
virtual

Add a new registered endpoint to the server database. Once the endpoint has been added it is then owned by the server and will be deleted when it is removed.

The user woiuld not usually use this function as it is used internally by the server when new registration requests (RRQ) are received.

Note that a registered endpoint has no relationship in this software to a H323EndPoint class.

virtual PString H323GatekeeperServer::AllocateAlias ( H225_RegistrationRequest &  rrq)
virtual
virtual unsigned H323GatekeeperServer::AllocateBandwidth ( unsigned  newBandwidth,
unsigned  oldBandwidth = 0 
)
virtual

Allocate or change the bandwidth being used. This function modifies the total bandwidth used by the all endpoints registered with this gatekeeper. It is called when ARQ or BRQ PDU's are received.

virtual PBoolean H323GatekeeperServer::AllowDuplicateAlias ( const H225_ArrayOf_AliasAddress &  )
inlinevirtual
virtual PBoolean H323GatekeeperServer::CheckAliasAddressPolicy ( const H323RegisteredEndPoint ep,
const H225_AdmissionRequest &  arq,
const H225_AliasAddress &  alias 
)
virtual

Check the alias address against the security policy. This validates that the specified endpoint is allowed to make a connection to or from the specified alias address.

It is expected that a user would override this function to implement application specified security policy algorithms.

The default behaviour checks the canOnlyAnswerRegisteredEP or canOnlyCallRegisteredEP meber variables depending on if it is an incoming call and if that is true only allows the call to proceed if the alias is also registered with the gatekeeper.

virtual PBoolean H323GatekeeperServer::CheckAliasStringPolicy ( const H323RegisteredEndPoint ep,
const H225_AdmissionRequest &  arq,
const PString &  alias 
)
virtual

Check the alias address against the security policy. This validates that the specified endpoint is allowed to make a connection to or from the specified simple alias string.

It is expected that a user would override this function to implement application specified security policy algorithms.

The default behaviour checks the canOnlyAnswerRegisteredEP or canOnlyCallRegisteredEP meber variables depending on if it is an incoming call and if that is true only allows the call to proceed if the alias is also registered with the gatekeeper.

virtual PBoolean H323GatekeeperServer::CheckSignalAddressPolicy ( const H323RegisteredEndPoint ep,
const H225_AdmissionRequest &  arq,
const H323TransportAddress address 
)
virtual

Check the signal address against the security policy. This validates that the specified endpoint is allowed to make a connection to or from the specified signal address.

It is expected that a user would override this function to implement application specified security policy algorithms.

The default behaviour simply returns true.

virtual void H323GatekeeperServer::ClearPasswords ( )
inlinevirtual

References m_passwords.

virtual H323GatekeeperCall* H323GatekeeperServer::CreateCall ( const OpalGloballyUniqueID callIdentifier,
H323GatekeeperCall::Direction  direction 
)
virtual

Create a new call object. The user woiuld not usually use this function as it is used internally by the server when new calls (ARQ) are made.

However, a user may override this function to create objects that are user defined descendants of H323GatekeeperCall so the user can maintain extra information on a call by call basis.

virtual PString H323GatekeeperServer::CreateEndPointIdentifier ( )
virtual

Create a new unique identifier for the registered endpoint. The returned identifier must be unique over the lifetime of this gatekeeper server.

The default behaviour simply returns the string representation of the member variable nextIdentifier. There could be a problem in this implementation after 4,294,967,296 have been registered.

virtual H323Transactor* H323GatekeeperServer::CreateListener ( H323Transport transport)
virtual

Create a new H323GatkeeperListener. The user woiuld not usually use this function as it is used internally by the server when new listeners are added by H323TransportAddress.

However, a user may override this function to create objects that are user defined descendants of H323GatekeeperListener so the user can maintain extra information on a interface by interface basis.

Parameters
transportTransport for listener

Implements H323TransactionServer.

void H323GatekeeperServer::CreatePeerElement ( const H323TransportAddress h501Interface)

Create an associated peer element for the gatekeeper. The existing peer element is checked to be listening on the same interface as specified and if it is not it is changed to the specified address.

virtual H323RegisteredEndPoint* H323GatekeeperServer::CreateRegisteredEndPoint ( H323GatekeeperRequest request)
virtual

Create a new registered endpoint object. The user woiuld not usually use this function as it is used internally by the server when new GRQ or RRQ is received.

However, a user may override this function to create objects that are user defined descendants of H323RegisteredEndPoint so the user can maintain extra information on a endpoint by endpoint basis.

virtual PSafePtr<H323GatekeeperCall> H323GatekeeperServer::FindCall ( const PString &  description,
PSafetyMode  mode = PSafeReference 
)
virtual

Find the call given the identifier.

virtual PSafePtr<H323GatekeeperCall> H323GatekeeperServer::FindCall ( const OpalGloballyUniqueID callIdentifier,
PBoolean  answeringCall,
PSafetyMode  mode = PSafeReference 
)
virtual

Find the call given the identifier.

virtual PSafePtr<H323GatekeeperCall> H323GatekeeperServer::FindCall ( const OpalGloballyUniqueID callIdentifier,
H323GatekeeperCall::Direction  direction,
PSafetyMode  mode = PSafeReference 
)
virtual

Find the call given the identifier.

PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindDestinationEndPoint ( const OpalGloballyUniqueID id,
H323GatekeeperCall::Direction  direction 
)
virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointByAliasAddress ( const H225_AliasAddress &  alias,
PSafetyMode  mode = PSafeReadWrite 
)
virtual

Find a registered endpoint given its raw alias address.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointByAliasString ( const PString &  alias,
PSafetyMode  mode = PSafeReference 
)
virtual

Find a registered endpoint given its simple alias string.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointByIdentifier ( const PString &  identifier,
PSafetyMode  mode = PSafeReference 
)
virtual

Find a registered endpoint given its endpoint identifier.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointByPartialAlias ( const PString &  alias,
PSafetyMode  mode = PSafeReference 
)
virtual

Find the first registered endpoint given a partial alias string.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointByPrefixString ( const PString &  prefix,
PSafetyMode  mode = PSafeReference 
)
virtual

Find the first registered endpoint given a number prefix string.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointBySignalAddress ( const H323TransportAddress address,
PSafetyMode  mode = PSafeReference 
)
virtual

Find a registered endpoint given its signal address.

virtual PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::FindEndPointBySignalAddresses ( const H225_ArrayOf_TransportAddress &  addresses,
PSafetyMode  mode = PSafeReference 
)
virtual

Find a registered endpoint given a list of signal addresses.

unsigned H323GatekeeperServer::GetActiveCalls ( ) const
inline

Get the currently active call count.

References m_activeCalls.

unsigned H323GatekeeperServer::GetActiveRegistrations ( ) const
inline

Get the currently active registration count.

References m_byIdentifier.

virtual PBoolean H323GatekeeperServer::GetAdmissionRequestAuthentication ( H323GatekeeperARQ info,
H235Authenticators &  authenticators 
)
virtual

Get separate H.235 authentication for the connection. This allows an individual ARQ to override the authentical credentials used in H.235 based RAS for this particular connection.

A return value of false indicates to use the default credentials of the endpoint, while true indicates that new credentials are to be used.

The default behavour does nothing and returns false.

Parameters
infoARQ being constructed
authenticatorsNew authenticators for ARQ
bool H323GatekeeperServer::GetAliasCanBeHostName ( ) const
inline

Gatekeeper allows endpoint to simply register its host name/IP address.

References m_aliasCanBeHostName.

bool H323GatekeeperServer::GetAnswerCallPreGrantedARQ ( ) const
inline

Gatekeeper pre-grants all incoming calls to endpoint.

References m_answerCallPreGrantedARQ.

unsigned H323GatekeeperServer::GetAvailableBandwidth ( ) const
inline

Get the total bandwidth available in 100's of bits per second.

References m_totalBandwidth.

bool H323GatekeeperServer::GetCanHaveDuplicateAlias ( ) const
inline

Different endpoint can register with gatekeeper the same alias name as another endpoint.

References m_canHaveDuplicateAlias.

bool H323GatekeeperServer::GetCanHaveDuplicatePrefix ( ) const
inline

Gateways may register duplicate prefix E.164 numbers.

References m_canHaveDuplicatePrefix.

bool H323GatekeeperServer::GetCanOnlyAnswerRegisteredEP ( ) const
inline

Gatekeeper will only allow endpoint to answer another endpoint registered localy.

References m_canOnlyAnswerRegisteredEP.

bool H323GatekeeperServer::GetCanOnlyCallRegisteredEP ( ) const
inline

Gatekeeper will only allow EP to call another endpoint registered localy.

References m_canOnlyCallRegisteredEP.

unsigned H323GatekeeperServer::GetDefaultBandwidth ( ) const
inline

Get the default bandwidth for calls.

References m_defaultBandwidth.

WORD H323GatekeeperServer::GetDefaultUdpPort ( )
inlinevirtual
bool H323GatekeeperServer::GetDisengageOnHearbeatFail ( ) const
inline

Hang up call if heartbeat (IRR) fails.

References m_disengageOnHearbeatFail.

PSafePtr<H323GatekeeperCall> H323GatekeeperServer::GetFirstCall ( PSafetyMode  mode = PSafeReference)
inline

Get first endpoint for enumeration.

References m_activeCalls.

PSafePtr<H323RegisteredEndPoint> H323GatekeeperServer::GetFirstEndPoint ( PSafetyMode  mode = PSafeReference)
inline

Get first endpoint for enumeration.

References m_byIdentifier.

const PString& H323GatekeeperServer::GetGatekeeperIdentifier ( ) const
inline

Get the identifier name for this gatekeeper.

References m_gatekeeperIdentifier.

unsigned H323GatekeeperServer::GetInfoResponseRate ( ) const
inline

Get the default time for monitoring calls via IRR.

References m_defaultInfoResponseRate.

bool H323GatekeeperServer::GetMakeCallPreGrantedARQ ( ) const
inline

Gatekeeper pre-grants all outgoing calls from endpoint.

References m_makeCallPreGrantedARQ.

unsigned H323GatekeeperServer::GetMaxAliasToAllocate ( ) const
inline

Maximum value for aliases gatekeeper will allocate when endpoint does not provide one, 0 disables.

References m_maxAliasToAllocate.

unsigned H323GatekeeperServer::GetMaximumBandwidth ( ) const
inline

Get the maximum bandwidth for calls.

References m_maximumBandwidth.

unsigned H323GatekeeperServer::GetMinAliasToAllocate ( ) const
inline

Minimum value for aliases gatekeeper will allocate when endpoint does not provide one, 0 disables.

References m_minAliasToAllocate.

bool H323GatekeeperServer::GetOverwriteOnSameSignalAddress ( ) const
inline

Allow new registration to gatekeeper on a specific signal address to override previous registration.

References m_overwriteOnSameSignalAddress.

unsigned H323GatekeeperServer::GetPeakCalls ( ) const
inline

Get the peak calls count.

References m_peakCalls.

unsigned H323GatekeeperServer::GetPeakRegistrations ( ) const
inline

Get the peak registration count.

References m_peakRegistrations.

H323PeerElement* H323GatekeeperServer::GetPeerElement ( ) const
inline

Get the associated peer element for the gatekeeper.

References m_peerElement.

unsigned H323GatekeeperServer::GetRejectedCalls ( ) const
inline

Get the total calls rejected since start up.

References m_rejectedCalls.

unsigned H323GatekeeperServer::GetRejectedRegistrations ( ) const
inline

Get the total registrations rejected since start up.

References m_rejectedRegistrations.

unsigned H323GatekeeperServer::GetTimeToLive ( ) const
inline

Get the default time to live for new registered endpoints.

References m_defaultTimeToLive.

unsigned H323GatekeeperServer::GetTotalCalls ( ) const
inline

Get the total calls since start up.

References m_totalCalls.

unsigned H323GatekeeperServer::GetTotalRegistrations ( ) const
inline

Get the total registrations since start up.

References m_totalRegistrations.

unsigned H323GatekeeperServer::GetUsedBandwidth ( ) const
inline

Get the total bandwidth used in 100's of bits per second.

References m_usedBandwidth.

virtual PBoolean H323GatekeeperServer::GetUsersPassword ( const PString &  alias,
PString &  password,
H323RegisteredEndPoint registeredEndpoint 
) const
virtual

Get password for user if H.235 security active. Returns true if user is found and password returned. Note the password may be empty in which case the user was found but explicitly ddoes not require security, possibly overriding the requireH235 flag.

virtual PBoolean H323GatekeeperServer::GetUsersPassword ( const PString &  alias,
PString &  password 
) const
virtual
bool H323GatekeeperServer::IsGatekeeperRouted ( ) const
inline

Get flag for is gatekeeper routed.

References m_isGatekeeperRouted.

bool H323GatekeeperServer::IsRequiredH235 ( ) const
inline

Get flag for if H.235 authentication is required.

References m_requireH235.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnAdmission ( H323GatekeeperARQ request)
virtual

Handle an admission ARQ PDU. The default behaviour verifies that the call is allowed by the policies the gatekeeper server requires, then attempts to look up the required signal address for the call. It also manages bandwidth allocations.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnBandwidth ( H323GatekeeperBRQ request)
virtual

Handle a bandwidth BRQ PDU. The default behaviour finds the call and does some checks then calls the H323GatekeeperCall function of the same name.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnDiscovery ( H323GatekeeperGRQ request)
virtual

Handle a discovery GRQ PDU. The default behaviour deals with the authentication scheme nogotiation.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnDisengage ( H323GatekeeperDRQ request)
virtual

Handle a disengage DRQ PDU. The default behaviour finds the call by its id provided in the DRQ and removes it from the gatekeeper server database.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnInfoResponse ( H323GatekeeperIRR request)
virtual

Handle an info request response IRR PDU. The default behaviour calls the function of the same name in the endpoint instance.

virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnLocation ( H323GatekeeperLRQ request)
virtual

Handle a location LRQ PDU. The default behaviour just uses TranslateAliasAddressToSignalAddress to determine the endpoints location.

It is expected that a user would override this function to implement application specified look up algorithms.

virtual void H323GatekeeperServer::OnReceiveFeatureSet ( H460_MessageType  pduType,
const H225_FeatureSet &  features 
) const
virtual
virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnRegistration ( H323GatekeeperRRQ request)
virtual

Call back on receiving a RAS registration for this endpoint. The default behaviour checks if the registered endpoint already exists and if not creates a new endpoint. It then calls the OnRegistration() on that new endpoint instance.

If returns true then a RCF is sent otherwise an RRJ is sent.

virtual PBoolean H323GatekeeperServer::OnSendDescriptorForEndpoint ( H323RegisteredEndPoint ,
H225_ArrayOf_AliasAddress &  ,
H225_EndpointType &  ,
H225_ArrayOf_AliasAddress &   
)
inlinevirtual
virtual PBoolean H323GatekeeperServer::OnSendFeatureSet ( H460_MessageType  pduType,
H225_FeatureSet &  features 
) const
virtual
virtual H323GatekeeperRequest::Response H323GatekeeperServer::OnUnregistration ( H323GatekeeperURQ request)
virtual

Handle an unregistration URQ PDU. The default behaviour removes the aliases defined in the URQ and if all aliases for the registered endpoint are removed then the endpoint itself is removed.

bool H323GatekeeperServer::OpenPeerElement ( const H323TransportAddress remotePeer,
bool  append = false,
bool  keepTrying = true 
)

Create a new Peer Element and establish a service relationship. If append is false, the existing peer element is automatically deleted and recreated. If append is true then a new service relationship is added to the existing peer element.

H323GatekeeperServer::P_REMOVE_VIRTUAL ( H323RegisteredEndPoint ,
CreateRegisteredEndPoint(H323GatekeeperRRQ &)  ,
 
)
protected
H323GatekeeperServer::PDECLARE_NOTIFIER ( PThread  ,
H323GatekeeperServer  ,
MonitorMain   
)
protected
H323GatekeeperServer::PLIST ( ListenerList  ,
H323GatekeeperListener   
)
protected
void H323GatekeeperServer::RemoveAlias ( H323RegisteredEndPoint ep,
const PString &  alias 
)
virtual void H323GatekeeperServer::RemoveCall ( H323GatekeeperCall call)
virtual

Called whenever call is ended. By default, removes the call from the call list

virtual PBoolean H323GatekeeperServer::RemoveEndPoint ( H323RegisteredEndPoint ep)
virtual

Remove a registered endpoint from the server database.

void H323GatekeeperServer::SetAliasCanBeHostName ( bool  v)
inline

References m_aliasCanBeHostName.

void H323GatekeeperServer::SetAnswerCallPreGrantedARQ ( bool  v)
inline
void H323GatekeeperServer::SetAvailableBandwidth ( unsigned  bps100)
inline

Set the total bandwidth available in 100's of bits per second.

References m_totalBandwidth.

void H323GatekeeperServer::SetCanHaveDuplicateAlias ( bool  v)
inline
void H323GatekeeperServer::SetCanHaveDuplicatePrefix ( bool  v)
inline
void H323GatekeeperServer::SetCanOnlyAnswerRegisteredEP ( bool  v)
inline
void H323GatekeeperServer::SetCanOnlyCallRegisteredEP ( bool  v)
inline
void H323GatekeeperServer::SetDefaultBandwidth ( unsigned  bw)
inline

References m_defaultBandwidth.

void H323GatekeeperServer::SetDisengageOnHearbeatFail ( bool  v)
inline
void H323GatekeeperServer::SetGatekeeperIdentifier ( const PString &  id,
bool  adjustListeners = true 
)

Set the identifier name for this gatekeeper. If adjustListeners is true then all gatekeeper listeners that are attached to this gatekeeper server have their identifier names changed as well.

void H323GatekeeperServer::SetGatekeeperRouted ( bool  is)
inline

References m_isGatekeeperRouted.

void H323GatekeeperServer::SetInfoResponseRate ( unsigned  seconds)
inline

Set the default time for monitoring calls via IRR.

References m_defaultInfoResponseRate.

void H323GatekeeperServer::SetMakeCallPreGrantedARQ ( bool  v)
inline
void H323GatekeeperServer::SetMaxAliasToAllocate ( unsigned  v)
inline

References m_maxAliasToAllocate.

void H323GatekeeperServer::SetMaximumBandwidth ( unsigned  bw)
inline

References m_maximumBandwidth.

void H323GatekeeperServer::SetMinAliasToAllocate ( unsigned  v)
inline

References m_minAliasToAllocate.

void H323GatekeeperServer::SetOverwriteOnSameSignalAddress ( bool  v)
inline
void H323GatekeeperServer::SetPeerElement ( H323PeerElement newPeerElement)

Set the associated peer element for the gatekeeper. The existing peer element is automatically deleted.

void H323GatekeeperServer::SetRequiredH235 ( bool  req)
inline

References m_requireH235.

void H323GatekeeperServer::SetTimeToLive ( unsigned  seconds)
inline

Set the default time to live for new registered endpoints.

References m_defaultTimeToLive.

virtual void H323GatekeeperServer::SetUsersPassword ( const PString &  alias,
const PString &  password 
)
virtual
virtual PBoolean H323GatekeeperServer::TranslateAliasAddress ( const H225_AliasAddress &  alias,
H225_ArrayOf_AliasAddress &  aliases,
H323TransportAddress address,
PBoolean &  isGkRouted,
H323GatekeeperCall call 
)
virtual

Translate a given alias to an alias set and signal address. This is called by the OnAdmission() handler to fill in the ACF or OnLocation() to fill the LCF informing the calling endpoint where to actually connect to.

It is expected that a user would override this function to implement application specified look up algorithms.

The default behaviour calls TranslateAliasAddressToSignalAddress() which is provided only for backwards compatibility.

virtual PBoolean H323GatekeeperServer::TranslateAliasAddressToSignalAddress ( const H225_AliasAddress &  alias,
H323TransportAddress address 
)
virtual

Translate a given alias to a signal address. This is called by the OnAdmission() handler to fill in the ACF or OnLocation() to fill the LCF informing the calling endpoint where to actually connect to.

It is expected that a user would override this function to implement application specified look up algorithms.

The default behaviour checks the isGatekeeperRouted and if true simply returns the gatekeepers associated endpoints (not registered endpoint, but real H323EndPoint) listening address.

If isGatekeeperRouted is false then it looks up the registered endpoints by alias and uses the saved signal address in the database.

If the alias is not registered then the address parameter is not changed and the function returns true if it is a valid address, false if it was empty.

Friends And Related Function Documentation

friend class H323GatekeeperARQ
friend
friend class H323GatekeeperRRQ
friend

Field Documentation

PSafeSortedList<H323GatekeeperCall> H323GatekeeperServer::m_activeCalls
protected

Referenced by GetActiveCalls(), and GetFirstCall().

bool H323GatekeeperServer::m_aliasCanBeHostName
protected
unsigned H323GatekeeperServer::m_aliasToAllocate
protected
bool H323GatekeeperServer::m_answerCallPreGrantedARQ
protected
PSortedStringList H323GatekeeperServer::m_byAddress
protected
PSortedStringList H323GatekeeperServer::m_byAlias
protected
PSafeDictionary<PString, H323RegisteredEndPoint> H323GatekeeperServer::m_byIdentifier
protected
PSortedStringList H323GatekeeperServer::m_byVoicePrefix
protected
bool H323GatekeeperServer::m_canHaveDuplicateAlias
protected
bool H323GatekeeperServer::m_canHaveDuplicatePrefix
protected
bool H323GatekeeperServer::m_canOnlyAnswerRegisteredEP
protected
bool H323GatekeeperServer::m_canOnlyCallRegisteredEP
protected
unsigned H323GatekeeperServer::m_defaultBandwidth
protected
unsigned H323GatekeeperServer::m_defaultInfoResponseRate
protected
unsigned H323GatekeeperServer::m_defaultTimeToLive
protected

Referenced by GetTimeToLive(), and SetTimeToLive().

PSafeDictionary<H225_AliasAddress, H323RegisteredEndPoint> H323GatekeeperServer::m_discoveredEndpoints
protected
bool H323GatekeeperServer::m_disengageOnHearbeatFail
protected
PString H323GatekeeperServer::m_gatekeeperIdentifier
protected

Referenced by GetGatekeeperIdentifier().

time_t H323GatekeeperServer::m_identifierBase
protected
bool H323GatekeeperServer::m_isGatekeeperRouted
protected
ListenerList H323GatekeeperServer::m_listeners
protected
bool H323GatekeeperServer::m_makeCallPreGrantedARQ
protected
unsigned H323GatekeeperServer::m_maxAliasToAllocate
protected
unsigned H323GatekeeperServer::m_maximumBandwidth
protected
unsigned H323GatekeeperServer::m_minAliasToAllocate
protected
PSyncPoint H323GatekeeperServer::m_monitorExit
protected
PThread* H323GatekeeperServer::m_monitorThread
protected
unsigned H323GatekeeperServer::m_nextIdentifier
protected
bool H323GatekeeperServer::m_overwriteOnSameSignalAddress
protected
PStringToString H323GatekeeperServer::m_passwords
protected

Referenced by ClearPasswords().

PINDEX H323GatekeeperServer::m_peakCalls
protected

Referenced by GetPeakCalls().

PINDEX H323GatekeeperServer::m_peakRegistrations
protected

Referenced by GetPeakRegistrations().

H323PeerElement* H323GatekeeperServer::m_peerElement
protected

Referenced by GetPeerElement().

PAtomicInteger H323GatekeeperServer::m_rejectedCalls
protected

Referenced by GetRejectedCalls().

PAtomicInteger H323GatekeeperServer::m_rejectedRegistrations
protected
bool H323GatekeeperServer::m_requireH235
protected

Referenced by IsRequiredH235(), and SetRequiredH235().

unsigned H323GatekeeperServer::m_totalBandwidth
protected
PINDEX H323GatekeeperServer::m_totalCalls
protected

Referenced by GetTotalCalls().

PINDEX H323GatekeeperServer::m_totalRegistrations
protected

Referenced by GetTotalRegistrations().

unsigned H323GatekeeperServer::m_usedBandwidth
protected

Referenced by GetUsedBandwidth().


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