Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 599901 Details for
Bug 842498
ISC-DHCP server with LDAP configuration does not respect FailOver options
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch to allow FailOverPeer's to be configured with LDAP backend.
dhcp-4.2.4-FailOverPeer.patch (text/plain), 41.35 KB, created by
William Brown
on 2012-07-24 03:36:25 UTC
(
hide
)
Description:
Patch to allow FailOverPeer's to be configured with LDAP backend.
Filename:
MIME Type:
Creator:
William Brown
Created:
2012-07-24 03:36:25 UTC
Size:
41.35 KB
patch
obsolete
>diff -uNrp dhcp-4.2.4.old/contrib/ldap/dhcp.schema dhcp-4.2.4.work/contrib/ldap/dhcp.schema >--- dhcp-4.2.4.old/contrib/ldap/dhcp.schema 2010-03-26 01:57:16.000000000 +1030 >+++ dhcp-4.2.4.work/contrib/ldap/dhcp.schema 2012-07-22 18:25:30.566520687 +0930 >@@ -334,6 +334,12 @@ attributetype ( 2.16.840.1.113719.1.203. > DESC 'Generic attribute that allows coments within any DHCP object' > SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 SINGLE-VALUE ) > >+attributetype ( 2.16.840.1.113719.1.203.4.57 >+ NAME 'dhcpFailOverDN' >+ EQUALITY distinguishedNameMatch >+ DESC 'The DN of the FailOver group that a shared IP pool will use.' >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 ) >+ > # Classes > > objectclass ( 2.16.840.1.113719.1.203.6.1 >@@ -362,7 +368,7 @@ objectclass ( 2.16.840.1.113719.1.203.6. > DESC 'This stores configuration information about a pool.' > SUP top > MUST ( cn $ dhcpRange ) >- MAY ( dhcpClassesDN $ dhcpPermitList $ dhcpLeasesDN $ dhcpOptionsDN $ dhcpZoneDN $dhcpKeyDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ MAY ( dhcpClassesDN $ dhcpPermitList $ dhcpLeasesDN $ dhcpOptionsDN $ dhcpZoneDN $dhcpKeyDN $ dhcpStatements $ dhcpComments $ dhcpOption $ dhcpFailOverDN ) > X-NDS_CONTAINMENT ('dhcpSubnet' 'dhcpSharedNetwork') ) > > objectclass ( 2.16.840.1.113719.1.203.6.5 >diff -uNrp dhcp-4.2.4.old/contrib/ldap/dhcp.schema.ldif dhcp-4.2.4.work/contrib/ldap/dhcp.schema.ldif >--- dhcp-4.2.4.old/contrib/ldap/dhcp.schema.ldif 1970-01-01 09:30:00.000000000 +0930 >+++ dhcp-4.2.4.work/contrib/ldap/dhcp.schema.ldif 2012-07-22 18:45:50.777225480 +0930 >@@ -0,0 +1,782 @@ >+# >+################################################################################ >+# >+dn: cn=schema >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.1 >+ NAME 'dhcpPrimaryDN' >+ DESC 'The DN of the dhcpServer which is the primary server for the configuration.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.2 >+ NAME 'dhcpSecondaryDN' >+ DESC 'The DN of dhcpServer(s) which provide backup service for the configuration.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.3 >+ NAME 'dhcpStatements' >+ DESC 'Flexible storage for specific data depending on what object this exists in. Like conditional statements, server parameters, etc. This allows the standard to evolve without needing to adjust the schema.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.4 >+ NAME 'dhcpRange' >+ DESC 'The starting & ending IP Addresses in the range (inclusive), separated by a hyphen; if the range only contains one address, then just the address can be specified with no hyphen. Each range is defined as a separate value.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.5 >+ NAME 'dhcpPermitList' >+ DESC 'This attribute contains the permit lists associated with a pool. Each permit list is defined as a separate value.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.6 >+ NAME 'dhcpNetMask' >+ DESC 'The subnet mask length for the subnet. The mask can be easily computed from this length.' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.7 >+ NAME 'dhcpOption' >+ DESC 'Encoded option values to be sent to clients. Each value represents a single option and contains (OptionTag, Length, OptionValue) encoded in the format used by DHCP.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.8 >+ NAME 'dhcpClassData' >+ DESC 'Encoded text string or list of bytes expressed in hexadecimal, separated by colons. Clients match subclasses based on matching the class data with the results of match or spawn with statements in the class name declarations.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.9 >+ NAME 'dhcpOptionsDN' >+ DESC 'The distinguished name(s) of the dhcpOption objects containing the configuration options provided by the server.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.10 >+ NAME 'dhcpHostDN' >+ DESC 'the distinguished name(s) of the dhcpHost objects.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.11 >+ NAME 'dhcpPoolDN' >+ DESC 'The distinguished name(s) of pools.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.12 >+ NAME 'dhcpGroupDN' >+ DESC 'The distinguished name(s) of the groups.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.13 >+ NAME 'dhcpSubnetDN' >+ DESC 'The distinguished name(s) of the subnets.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.14 >+ NAME 'dhcpLeaseDN' >+ DESC 'The distinguished name of a client address.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.15 >+ NAME 'dhcpLeasesDN' >+ DESC 'The distinguished name(s) client addresses.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.16 >+ NAME 'dhcpClassesDN' >+ DESC 'The distinguished name(s) of a class(es) in a subclass.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.17 >+ NAME 'dhcpSubclassesDN' >+ DESC 'The distinguished name(s) of subclass(es).' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.18 >+ NAME 'dhcpSharedNetworkDN' >+ DESC 'The distinguished name(s) of sharedNetworks.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.19 >+ NAME 'dhcpServiceDN' >+ DESC 'The DN of dhcpService object(s)which contain the configuration information. Each dhcpServer object has this attribute identifying the DHCP configuration(s) that the server is associated with.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.20 >+ NAME 'dhcpVersion' >+ DESC 'The version attribute of this object.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.21 >+ NAME 'dhcpImplementation' >+ DESC 'Description of the DHCP Server implementation e.g. DHCP Servers vendor.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.22 >+ NAME 'dhcpAddressState' >+ DESC 'This stores information about the current binding-status of an address. For dynamic addresses managed by DHCP, the values should be restricted to the following: "FREE", "ACTIVE", "EXPIRED", "RELEASED", "RESET", "ABANDONED", "BACKUP". For other addresses, it SHOULD be one of the following: "UNKNOWN", "RESERVED" (an address that is managed by DHCP that is reserved for a specific client), "RESERVED-ACTIVE" (same as reserved, but address is currently in use), "ASSIGNED" (assigned manually or by some other mechanism), "UNASSIGNED", "NOTASSIGNABLE".' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.23 >+ NAME 'dhcpExpirationTime' >+ DESC 'This is the time the current lease for an address expires.' >+ EQUALITY generalizedTimeMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.24 >+ NAME 'dhcpStartTimeOfState' >+ DESC 'This is the time of the last state change for a leased address.' >+ EQUALITY generalizedTimeMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.25 >+ NAME 'dhcpLastTransactionTime' >+ DESC 'This is the last time a valid DHCP packet was received from the client.' >+ EQUALITY generalizedTimeMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.24 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.26 >+ NAME 'dhcpBootpFlag' >+ DESC 'This indicates whether the address was assigned via BOOTP.' >+ EQUALITY booleanMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.27 >+ NAME 'dhcpDomainName' >+ DESC 'This is the name of the domain sent to the client by the server. It is essentially the same as the value for DHCP option 15 sent to the client, and represents only the domain - not the full FQDN. To obtain the full FQDN assigned to the client you must prepend the "dhcpAssignedHostName" to this value with a ".".' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.28 >+ NAME 'dhcpDnsStatus' >+ DESC 'This indicates the status of updating DNS resource records on behalf of the client by the DHCP server for this address. The value is a 16-bit bitmask.' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.29 >+ NAME 'dhcpRequestedHostName' >+ DESC 'This is the hostname that was requested by the client.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.30 >+ NAME 'dhcpAssignedHostName' >+ DESC 'This is the actual hostname that was assigned to a client. It may not be the name that was requested by the client. The fully qualified domain name can be determined by appending the value of "dhcpDomainName" (with a dot separator) to this name.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.31 >+ NAME 'dhcpReservedForClient' >+ DESC 'The distinguished name of a "dhcpClient" that an address is reserved for. This may not be the same as the "dhcpAssignedToClient" attribute if the address is being reassigned but the current lease has not yet expired.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.32 >+ NAME 'dhcpAssignedToClient' >+ DESC 'This is the distinguished name of a "dhcpClient" that an address is currently assigned to. This attribute is only present in the class when the address is leased.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.33 >+ NAME 'dhcpRelayAgentInfo' >+ DESC 'If the client request was received via a relay agent, this contains information about the relay agent that was available from the DHCP request. This is a hex-encoded option value.' >+ EQUALITY octetStringMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.34 >+ NAME 'dhcpHWAddress' >+ DESC 'The clients hardware address that requested this IP address.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.35 >+ NAME 'dhcpHashBucketAssignment' >+ DESC 'HashBucketAssignment bit map for the DHCP Server, as defined in DHC Load Balancing Algorithm [RFC 3074].' >+ EQUALITY octetStringMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.36 >+ NAME 'dhcpDelayedServiceParameter' >+ DESC 'Delay in seconds corresponding to Delayed Service Parameter configuration, as defined in DHC Load Balancing Algorithm [RFC 3074]. ' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.37 >+ NAME 'dhcpMaxClientLeadTime' >+ DESC 'Maximum Client Lead Time configuration in seconds, as defined in DHCP Failover Protocol [FAILOVR]' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.38 >+ NAME 'dhcpFailOverEndpointState' >+ DESC 'Server (Failover Endpoint) state, as defined in DHCP Failover Protocol [FAILOVR]' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.39 >+ NAME 'dhcpErrorLog' >+ DESC 'Generic error log attribute that allows logging error conditions within a dhcpService or a dhcpSubnet, like no IP addresses available for lease.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.40 >+ NAME 'dhcpLocatorDN' >+ DESC 'The DN of dhcpLocator object which contain the DNs of all DHCP configuration objects. There will be a single dhcpLocator object in the tree with links to all the DHCP objects in the tree' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.41 >+ NAME 'dhcpKeyAlgorithm' >+ DESC 'Algorithm to generate TSIG Key' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.42 >+ NAME 'dhcpKeySecret' >+ DESC 'Secret to generate TSIG Key' >+ EQUALITY octetStringMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.43 >+ NAME 'dhcpDnsZoneServer' >+ DESC 'Master server of the DNS Zone' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.44 >+ NAME 'dhcpKeyDN' >+ DESC 'The DNs of TSIG Key to use in secure dynamic updates. In case of locator object, this will be list of TSIG keys. In case of DHCP Service, Shared Network, Subnet and DNS Zone, it will be a single key.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.45 >+ NAME 'dhcpZoneDN' >+ DESC 'The DNs of DNS Zone. In case of locator object, this will be list of DNS Zones in the tree. In case of DHCP Service, Shared Network and Subnet, it will be a single DNS Zone.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.46 >+ NAME 'dhcpFailOverPrimaryServer' >+ DESC 'IP address or DNS name of the server playing primary role in DHC Load Balancing and Fail over.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.47 >+ NAME 'dhcpFailOverSecondaryServer' >+ DESC 'IP address or DNS name of the server playing secondary role in DHC Load Balancing and Fail over.' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.48 >+ NAME 'dhcpFailOverPrimaryPort' >+ DESC 'Port on which primary server listens for connections from its fail over peer (secondary server)' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.49 >+ NAME 'dhcpFailOverSecondaryPort' >+ DESC 'Port on which secondary server listens for connections from its fail over peer (primary server)' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.50 >+ NAME 'dhcpFailOverResponseDelay' >+ DESC 'Maximum response time in seconds, before Server assumes that connection to fail over peer has failed' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.51 >+ NAME 'dhcpFailOverUnackedUpdates' >+ DESC 'Number of BNDUPD messages that server can send before it receives BNDACK from its fail over peer' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.52 >+ NAME 'dhcpFailOverSplit' >+ DESC 'Split between the primary and secondary servers for fail over purpose' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.53 >+ NAME 'dhcpFailOverLoadBalanceTime' >+ DESC 'Cutoff time in seconds, after which load balance is disabled' >+ EQUALITY integerMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.54 >+ NAME 'dhcpFailOverPeerDN' >+ DESC 'The DNs of Fail over peers. In case of locator object, this will be list of fail over peers in the tree. In case of Subnet and pool, it will be a single Fail Over Peer' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.55 >+ NAME 'dhcpServerDN' >+ DESC 'List of all DHCP Servers in the tree. Used by dhcpLocatorObject' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.56 >+ NAME 'dhcpComments' >+ DESC 'Generic attribute that allows coments within any DHCP object' >+ EQUALITY caseIgnoreIA5Match >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 >+ SINGLE-VALUE >+ ) >+# >+################################################################################ >+# >+attributeTypes: ( >+ 2.16.840.1.113719.1.203.4.57 >+ NAME 'dhcpFailOverDN' >+ DESC 'The DN of the FailOver group that a shared IP pool will use.' >+ EQUALITY distinguishedNameMatch >+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.1 >+ NAME 'dhcpService' >+ DESC 'Service object that represents the actual DHCP Service configuration. This is a container object.' >+ SUP top >+ MUST ( cn ) >+ MAY ( dhcpPrimaryDN $ dhcpSecondaryDN $ dhcpServerDN $ dhcpSharedNetworkDN $ dhcpSubnetDN $ dhcpGroupDN $ dhcpHostDN $ dhcpClassesDN $ dhcpOptionsDN $ dhcpZoneDN $ dhcpKeyDN $ dhcpFailOverPeerDN $ dhcpStatements $dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.2 >+ NAME 'dhcpSharedNetwork' >+ DESC 'This stores configuration information for a shared network.' >+ SUP top >+ MUST cn >+ MAY ( dhcpSubnetDN $ dhcpPoolDN $ dhcpOptionsDN $ dhcpZoneDN $ dhcpStatements $dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.3 >+ NAME 'dhcpSubnet' >+ DESC 'This class defines a subnet. This is a container object.' >+ SUP top >+ MUST ( cn $ dhcpNetMask ) >+ MAY ( dhcpRange $ dhcpPoolDN $ dhcpGroupDN $ dhcpHostDN $ dhcpClassesDN $ dhcpLeasesDN $ dhcpOptionsDN $ dhcpZoneDN $ dhcpKeyDN $ dhcpFailOverPeerDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.4 >+ NAME 'dhcpPool' >+ DESC 'This stores configuration information about a pool.' >+ SUP top >+ MUST ( cn $ dhcpRange ) >+ MAY ( dhcpClassesDN $ dhcpPermitList $ dhcpLeasesDN $ dhcpOptionsDN $ dhcpZoneDN $dhcpKeyDN $ dhcpStatements $ dhcpComments $ dhcpOption $ dhcpFailOverDN ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.5 >+ NAME 'dhcpGroup' >+ DESC 'Group object that lists host DNs and parameters. This is a container object.' >+ SUP top >+ MUST cn >+ MAY ( dhcpHostDN $ dhcpOptionsDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.6 >+ NAME 'dhcpHost' >+ DESC 'This represents information about a particular client' >+ SUP top >+ MUST cn >+ MAY ( dhcpLeaseDN $ dhcpHWAddress $ dhcpOptionsDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.7 >+ NAME 'dhcpClass' >+ DESC 'Represents information about a collection of related clients.' >+ SUP top >+ MUST cn >+ MAY ( dhcpSubClassesDN $ dhcpOptionsDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.8 >+ NAME 'dhcpSubClass' >+ DESC 'Represents information about a collection of related classes.' >+ SUP top >+ MUST cn >+ MAY ( dhcpClassData $ dhcpOptionsDN $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.9 >+ NAME 'dhcpOptions' >+ DESC 'Represents information about a collection of options defined.' >+ SUP top >+ AUXILIARY >+ MUST cn >+ MAY ( dhcpOption $ dhcpComments ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.10 >+ NAME 'dhcpLeases' >+ DESC 'This class represents an IP Address, which may or may not have been leased.' >+ SUP top >+ MUST ( cn $ dhcpAddressState ) >+ MAY ( dhcpExpirationTime $ dhcpStartTimeOfState $ dhcpLastTransactionTime $ dhcpBootpFlag $ dhcpDomainName $ dhcpDnsStatus $ dhcpRequestedHostName $ dhcpAssignedHostName $ dhcpReservedForClient $ dhcpAssignedToClient $ dhcpRelayAgentInfo $ dhcpHWAddress ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.11 >+ NAME 'dhcpLog' >+ DESC 'This is the object that holds past information about the IP address. The cn is the time/date stamp when the address was assigned or released, the address state at the time, if the address was assigned or released.' >+ SUP top >+ MUST ( cn ) >+ MAY ( dhcpAddressState $ dhcpExpirationTime $ dhcpStartTimeOfState $ dhcpLastTransactionTime $ dhcpBootpFlag $ dhcpDomainName $ dhcpDnsStatus $ dhcpRequestedHostName $ dhcpAssignedHostName $ dhcpReservedForClient $ dhcpAssignedToClient $ dhcpRelayAgentInfo $ dhcpHWAddress $ dhcpErrorLog ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.12 >+ NAME 'dhcpServer' >+ DESC 'DHCP Server Object' >+ SUP top >+ MUST ( cn ) >+ MAY ( dhcpServiceDN $ dhcpLocatorDN $ dhcpVersion $ dhcpImplementation $ dhcpHashBucketAssignment $ dhcpDelayedServiceParameter $ dhcpMaxClientLeadTime $ dhcpFailOverEndpointState $ dhcpStatements $ dhcpComments $ dhcpOption ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.13 >+ NAME 'dhcpTSigKey' >+ DESC 'TSIG key for secure dynamic updates' >+ SUP top >+ MUST ( cn $ dhcpKeyAlgorithm $ dhcpKeySecret ) >+ MAY ( dhcpComments ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.14 >+ NAME 'dhcpDnsZone' >+ DESC 'DNS Zone for updating leases' >+ SUP top >+ MUST ( cn $ dhcpDnsZoneServer ) >+ MAY ( dhcpKeyDN $ dhcpComments ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.15 >+ NAME 'dhcpFailOverPeer' >+ DESC 'This class defines the Fail over peer' >+ SUP top >+ MUST ( cn $ dhcpFailOverPrimaryServer $ dhcpFailOverSecondaryServer $ dhcpFailoverPrimaryPort $ dhcpFailOverSecondaryPort ) >+ MAY ( dhcpFailOverResponseDelay $ dhcpFailOverUnackedUpdates $ dhcpMaxClientLeadTime $ dhcpFailOverSplit $ dhcpHashBucketAssignment $ dhcpFailOverLoadBalanceTime $ dhcpComments ) >+ ) >+# >+################################################################################ >+# >+objectClasses: ( >+ 2.16.840.1.113719.1.203.6.16 >+ NAME 'dhcpLocator' >+ DESC 'Locator object for DHCP configuration in the tree. There will be a single dhcpLocator object in the tree with links to all the DHCP objects in the tree' >+ SUP top >+ MUST ( cn ) >+ MAY ( dhcpServiceDN $dhcpServerDN $ dhcpSharedNetworkDN $ dhcpSubnetDN $ dhcpPoolDN $ dhcpGroupDN $ dhcpHostDN $ dhcpClassesDN $ dhcpKeyDN $ dhcpZoneDN $ dhcpFailOverPeerDN $ dhcpOption $ dhcpComments ) >+ ) >+# >+################################################################################ >+# >diff -uNrp dhcp-4.2.4.old/server/ldap.c dhcp-4.2.4.work/server/ldap.c >--- dhcp-4.2.4.old/server/ldap.c 2012-07-04 07:25:43.807456040 +0930 >+++ dhcp-4.2.4.work/server/ldap.c 2012-07-23 05:39:33.766054951 +0930 >@@ -222,6 +222,56 @@ parse_netmask (int netmask, char *netmas > } > > >+static int >+getfqhostname(char *fqhost, size_t size) >+{ >+#if defined(MAXHOSTNAMELEN) >+ char hname[MAXHOSTNAMELEN]; >+#else >+ char hname[65]; >+#endif >+ struct hostent *hp; >+ >+ if(NULL == fqhost || 1 >= size) >+ return -1; >+ >+ memset(hname, 0, sizeof(hname)); >+ if( gethostname(hname, sizeof(hname)-1)) >+ return -1; >+ >+ if(NULL == (hp = gethostbyname(hname))) >+ return -1; >+ >+ strncpy(fqhost, hp->h_name, size-1); >+ fqhost[size-1] = '\0'; >+ return 0; >+} >+ >+ >+static int >+gethostnametoip(char *dst, char *hostname) >+{ >+ struct addrinfo hints, *servinfo, *p; >+ struct sockaddr_in *h; >+ int rv = 0; >+ >+ memset(&hints, 0, sizeof(hints)); >+ hints.ai_family = AF_UNSPEC; // use AF_INET6 to force IPv6 >+ hints.ai_socktype = SOCK_STREAM; >+ if ( (rv = getaddrinfo( hostname , "http" , &hints , &servinfo)) != 0) >+ { >+ log_error ("getaddrinfo: %s\n", gai_strerror(rv)); >+ return rv; >+ } >+ for ( p = servinfo; p != NULL; p = p->ai_next) >+ { >+ h = (struct sockaddr_in * ) p->ai_addr; >+ strcpy(dst, inet_ntoa(h->sin_addr)); >+ } >+ freeaddrinfo(servinfo); >+ return 0; >+} >+ > static void > ldap_parse_subnet (struct ldap_config_stack *item, struct parse *cfile) > { >@@ -284,6 +334,9 @@ ldap_parse_pool (struct ldap_config_stac > > x_strncat (cfile->inbuf, "pool {\n", LDAP_BUFFER_SIZE); > >+ // TODO - This should also have a new attribute, dhcpFailOver that lists the failover pool we are in. >+ // This could be the DN, but we don't want to "accidentaly" follow it, but the DN makes the most sense ... >+ > if ((tempbv = ldap_get_values_len (ld, item->ldent, "dhcpRange")) != NULL) > { > x_strncat (cfile->inbuf, "range", LDAP_BUFFER_SIZE); >@@ -306,6 +359,28 @@ ldap_parse_pool (struct ldap_config_stac > ldap_value_free_len (tempbv); > } > >+ if ((tempbv = ldap_get_values_len (ld, item->ldent, "dhcpFailOverDN")) != NULL) >+ { >+ if (tempbv != NULL && tempbv[0] != NULL) >+ { >+#if defined (DEBUG_LDAP) >+ log_info ("ldap_parse_pool : FailOver DN %s", tempbv[0]->bv_val); >+#endif >+ char delims[] = "=,"; >+ char *result = NULL; >+ result = strtok( tempbv[0]->bv_val, delims ); >+ if (result != NULL) >+ { >+ x_strncat (cfile->inbuf, "failover peer \"", LDAP_BUFFER_SIZE); >+ //We don't need the whole string - we just need the first cn attr from index(tempbv[0]->bv_val, '=') going up to the first ',' >+ x_strncat (cfile->inbuf, strtok( NULL, delims) , LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, "\";\n", LDAP_BUFFER_SIZE); >+ } >+ } >+ ldap_value_free_len (tempbv); >+ } >+ >+ > item->close_brace = 1; > } > >@@ -415,6 +490,210 @@ ldap_parse_zone (struct ldap_config_stac > > > static void >+ldap_parse_failoverpeer (struct ldap_config_stack *item, struct parse *cfile) >+{ >+ struct berval **tempbv, **primary, **secondary, **primaryport, **secondaryport; >+ struct berval **self, **selfport, **peer, **peerport; >+ struct berval **split, **responsedelay, **unackedupdates, **clientleadtime, **hashbucket; >+ struct berval **loadbalancetime, **comments; >+ char fqdn[257], ip[100], peerip[100]; >+ char hostname[257]; >+ int role = 0; >+ struct utsname unme; >+ >+ if ((tempbv = ldap_get_values_len (ld, item->ldent, "cn")) == NULL || >+ tempbv[0] == NULL) >+ { >+ if (tempbv != NULL) >+ ldap_value_free_len (tempbv); >+ >+ return; >+ } >+ >+ //These are mandatory >+ primary = ldap_get_values_len (ld, item->ldent, "dhcpFailOverPrimaryServer"); >+ secondary = ldap_get_values_len (ld, item->ldent, "dhcpFailOverSecondaryServer"); >+ primaryport = ldap_get_values_len (ld, item->ldent, "dhcpFailOverPrimaryPort"); >+ secondaryport = ldap_get_values_len (ld, item->ldent, "dhcpFailOverSecondaryPort"); >+ split = ldap_get_values_len (ld, item->ldent, "dhcpFailOverSplit"); >+ //These are optional >+ responsedelay = ldap_get_values_len (ld, item->ldent, "dhcpFailOverResponseDelay"); >+ unackedupdates = ldap_get_values_len (ld, item->ldent, "dhcpFailOverUnackedUpdates"); >+ clientleadtime = ldap_get_values_len (ld, item->ldent, "dhcpMaxClientLeadTime"); >+ hashbucket = ldap_get_values_len (ld, item->ldent, "dhcpHashBucketAssignment"); >+ loadbalancetime = ldap_get_values_len (ld, item->ldent, "dhcpFailOverLoadBalanceTime"); >+ //Should we bother with this .... ? >+ comments = ldap_get_values_len (ld, item->ldent, "dhcpComments"); >+ >+ // We should be a bit more robust - lets check we have all the options we need before we >+ // Jump in and start configuring things. >+ >+ if ( primary != NULL && >+ primary[0] != NULL && >+ secondary != NULL && >+ secondary[0] != NULL && >+ primaryport != NULL && >+ primaryport[0] != NULL && >+ secondaryport != NULL && >+ secondaryport[0] != NULL && >+ split != NULL && >+ split[0] != NULL && >+ clientleadtime != NULL && >+ clientleadtime[0] != NULL ) >+ { >+ >+ //We need to know our FQDN, to match against the primary / secondary item >+ // We always seem to have unme.nodename avaliable, but use fqdn if we can >+ if(0 == getfqhostname(fqdn, sizeof(fqdn))) >+ { >+ strcpy(hostname, fqdn); >+ } >+ else >+ { >+ strcpy(hostname, unme.nodename); >+ } >+#if defined (DEBUG_LDAP) >+ log_info ("ldap_parse_failoverpeer : hostname = %s " , hostname); >+#endif >+ >+ if(gethostnametoip(ip, hostname) != 0) >+ { >+ return; >+ } >+ >+ if ( (strcmp(hostname, primary[0]->bv_val) == 0) || >+ (strcmp(ip, primary[0]->bv_val) == 0 ) ) >+ { >+#if defined (DEBUG_LDAP) >+ log_info ("ldap_parse_failoverpeer : primary server"); >+#endif >+ role = 1; >+ self = primary; >+ selfport = primaryport; >+ peer = secondary; >+ peerport = secondaryport; >+ } >+ else if ( (strcmp(hostname, secondary[0]->bv_val) == 0) || >+ (strcmp(ip, secondary[0]->bv_val) == 0 )) >+ { >+#if defined (DEBUG_LDAP) >+ log_info ("ldap_parse_failoverpeer : secondary server"); >+#endif >+ role = 2; >+ self = secondary; >+ selfport = secondaryport; >+ peer = primary; >+ peerport = primaryport; >+ } >+ >+ if (role > 0) >+ { >+ if(gethostnametoip(peerip, peer[0]->bv_val) != 0) >+ { >+ log_info ("ldap_parse_failoverpeer : Error resolving failover peer"); >+ return; >+ } >+ // We don't even start writing config unless we know that we are >+ // a primary or a secondary >+ >+ x_strncat (cfile->inbuf, "failover peer \"", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, tempbv[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, "\" {\n" , LDAP_BUFFER_SIZE); >+ if (role == 1) >+ { >+ x_strncat (cfile->inbuf, "primary;\n", LDAP_BUFFER_SIZE); >+ } >+ else if (role == 2) >+ { >+ x_strncat (cfile->inbuf, "secondary;\n", LDAP_BUFFER_SIZE); >+ } >+ >+ x_strncat (cfile->inbuf, "address ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ip, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ >+ x_strncat (cfile->inbuf, "port ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, selfport[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ >+ x_strncat (cfile->inbuf, "peer address ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, peerip, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ >+ x_strncat (cfile->inbuf, "peer port ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, peerport[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ >+ if (role == 1) >+ { >+ x_strncat (cfile->inbuf, "split ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, split[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ >+ x_strncat (cfile->inbuf, "mclt ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, clientleadtime[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ } >+ >+ if (responsedelay != NULL && responsedelay[0] != NULL) >+ { >+ x_strncat (cfile->inbuf, "max-response-delay ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, responsedelay[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ } >+ >+ if (unackedupdates != NULL && unackedupdates[0] != NULL) >+ { >+ x_strncat (cfile->inbuf, "max-unacked-updates ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, unackedupdates[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ } >+ >+ //TODO - What is the dhcpd.conf option for this? >+ //if (hashbucket != NULL && hashbucket[0] != NULL) >+ // { >+ // x_strncat (cfile->inbuf, "max-response-delay ", LDAP_BUFFER_SIZE); >+ // x_strncat (cfile->inbuf, hashbucket[0]->bv_val, LDAP_BUFFER_SIZE); >+ // x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ // } >+ >+ if (loadbalancetime != NULL && loadbalancetime[0] != NULL) >+ { >+ x_strncat (cfile->inbuf, "load balance max seconds ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, loadbalancetime[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, ";\n", LDAP_BUFFER_SIZE); >+ } >+ >+ if (comments != NULL && comments[0] != NULL) >+ { >+ x_strncat (cfile->inbuf, "## ", LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, comments[0]->bv_val, LDAP_BUFFER_SIZE); >+ x_strncat (cfile->inbuf, "\n", LDAP_BUFFER_SIZE); >+ } >+ item->close_brace = 1; >+ } >+ else >+ { >+ log_info ("ldap_parse_failoverpeer : Server does not match primary or secondary failover server, or split information missing"); >+ } >+ >+ } >+ >+ ldap_value_free_len (primary); >+ ldap_value_free_len (secondary); >+ ldap_value_free_len (primaryport); >+ ldap_value_free_len (secondaryport); >+ ldap_value_free_len (tempbv); >+ ldap_value_free_len (split); >+ ldap_value_free_len (responsedelay); >+ ldap_value_free_len (unackedupdates); >+ ldap_value_free_len (clientleadtime); >+ ldap_value_free_len (hashbucket); >+ ldap_value_free_len (loadbalancetime); >+ ldap_value_free_len (comments); >+} >+ >+static void > add_to_config_stack (LDAPMessage * res, LDAPMessage * ent) > { > struct ldap_config_stack *ns; >@@ -1150,7 +1429,9 @@ ldap_generate_config_string (struct pars > found = 1; > for (i=0; objectClass[i] != NULL; i++) > { >- if (strcasecmp (objectClass[i]->bv_val, "dhcpSharedNetwork") == 0) >+ if (strcasecmp (objectClass[i]->bv_val, "dhcpFailOverPeer") == 0) >+ ldap_parse_failoverpeer (entry, cfile); >+ else if (strcasecmp (objectClass[i]->bv_val, "dhcpSharedNetwork") == 0) > ldap_parse_shared_network (entry, cfile); > else if (strcasecmp (objectClass[i]->bv_val, "dhcpClass") == 0) > ldap_parse_class (entry, cfile); >@@ -1322,32 +1603,6 @@ ldap_get_host_name (LDAPMessage * ent) > } > > >-static int >-getfqhostname(char *fqhost, size_t size) >-{ >-#if defined(MAXHOSTNAMELEN) >- char hname[MAXHOSTNAMELEN]; >-#else >- char hname[65]; >-#endif >- struct hostent *hp; >- >- if(NULL == fqhost || 1 >= size) >- return -1; >- >- memset(hname, 0, sizeof(hname)); >- if( gethostname(hname, sizeof(hname)-1)) >- return -1; >- >- if(NULL == (hp = gethostbyname(hname))) >- return -1; >- >- strncpy(fqhost, hp->h_name, size-1); >- fqhost[size-1] = '\0'; >- return 0; >-} >- >- > isc_result_t > ldap_read_config (void) > {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 842498
:
599901
|
600007