RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 719089 - IPA dynamic DNS update mangles AAAA records
Summary: IPA dynamic DNS update mangles AAAA records
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: sssd
Version: 6.1
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: 6.2
Assignee: Stephen Gallagher
QA Contact: Chandrasekar Kannan
URL:
Whiteboard:
Depends On:
Blocks: 748853
TreeView+ depends on / blocked
 
Reported: 2011-07-05 18:08 UTC by Stephen Gallagher
Modified: 2020-05-04 10:21 UTC (History)
5 users (show)

Fixed In Version: sssd-1.5.1-42.el6
Doc Type: Bug Fix
Doc Text:
Cause: The buffer used by the dynamic DNS update code was not big enough to contain IPv6 addresses Consequence: Only part of the address was written into DNS, mangling the records Fix: A larger buffer that is able to contain all address families is used Result: dynamic DNS updates work correctly in an IPv6 environment
Clone Of:
: 748853 (view as bug list)
Environment:
Last Closed: 2011-12-06 16:39:00 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github SSSD sssd issues 1957 0 None closed IPA dynamic DNS update mangles AAAA records 2020-05-04 10:21:29 UTC
Red Hat Product Errata RHBA-2011:1529 0 normal SHIPPED_LIVE sssd bug fix and enhancement update 2011-12-06 00:50:20 UTC

Description Stephen Gallagher 2011-07-05 18:08:51 UTC
Description of problem:
When IPA dyndns update is used to update an AAAA records with an address detected from the LDAP socket, the address is truncated. The getsockname call still passes, so the user does not see any error except for the wrong IP address in DNS.

The root cause is that getsockname call uses struct sockaddr that is not big enough to hold v6 address. We should use sockaddr_storage. 

Version-Release number of selected component (if applicable):
sssd-1.5.1-34.el6_1.2

How reproducible:
Every time

Steps to Reproduce:
1. Enroll an IPA client
2. In sssd.conf, set ipa_dyndns_update = True
3. In sssd.conf, set ipa_dyndns_iface = eth0 (or another appropriate interface)

  
Actual results:
An incorrect IPv6 address will be updated into the DNS server for the AAAA record.

Expected results:
The correct IPv6 address is stored in the AAAA record.

Additional info:
Fixed upstream:
https://fedorahosted.org/sssd/ticket/915

Comment 3 Gowrishankar Rajaiyan 2011-10-03 10:20:06 UTC
# ifconfig 
eth0      Link encap:Ethernet  HWaddr 52:54:00:A6:0E:C8  
          inet6 addr: 2620:52:0:41c9:5054:ff:fea6:ec8/64 Scope:Global
          inet6 addr: fe80::5054:ff:fea6:ec8/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:863751 errors:0 dropped:0 overruns:0 frame:0
          TX packets:53833 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:233203133 (222.3 MiB)  TX bytes:17569208 (16.7 MiB)


[domain/lab.eng.pnq.redhat.com]
cache_credentials = True
krb5_store_password_if_offline = True
ipa_domain = lab.eng.pnq.redhat.com
id_provider = ipa
auth_provider = ipa
access_provider = permit
ipa_hostname = ratchet.lab.eng.pnq.redhat.com
chpass_provider = ipa
ipa_server = _srv_, jetfire.lab.eng.pnq.redhat.com
ldap_tls_cacert = /etc/ipa/ca.crt
debug_level = 9
ipa_dyndns_update = True
ipa_dyndns_iface = eth0



# ipa dnsrecord-find lab.eng.pnq.redhat.com
  Record name: @
  NS record: jetfire.lab.eng.pnq.redhat.com.

  Record name: _kerberos
  TXT record: LAB.ENG.PNQ.REDHAT.COM

  Record name: _kerberos-master._tcp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos-master._udp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos._tcp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos._udp
  SRV record: 0 100 88 jetfire

  Record name: _kpasswd._tcp
  SRV record: 0 100 464 jetfire

  Record name: _kpasswd._udp
  SRV record: 0 100 464 jetfire

  Record name: _ldap._tcp
  SRV record: 0 100 389 jetfire

  Record name: _ntp._udp
  SRV record: 0 100 123 jetfire

  Record name: jetfire
  AAAA record: 2620:52:0:41c9:5054:ff:fea8:b669
-----------------------------
Number of entries returned 11
-----------------------------


# ssh -l shanks $HOSTNAME
shanks.eng.pnq.redhat.com's password: 
Password expired. Change your password now.
ca issue with dual entries in /etc/hosts
WARNING: Your password has expired.
You must change your password now and login again!
Changing password for user shanks.
Current Password: 
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.
Connection to ratchet.lab.eng.pnq.redhat.com closed.


[root@jetfire ~]# ipa dnsrecord-find lab.eng.pnq.redhat.com
  Record name: @
  NS record: jetfire.lab.eng.pnq.redhat.com.

  Record name: _kerberos
  TXT record: LAB.ENG.PNQ.REDHAT.COM

  Record name: _kerberos-master._tcp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos-master._udp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos._tcp
  SRV record: 0 100 88 jetfire

  Record name: _kerberos._udp
  SRV record: 0 100 88 jetfire

  Record name: _kpasswd._tcp
  SRV record: 0 100 464 jetfire

  Record name: _kpasswd._udp
  SRV record: 0 100 464 jetfire

  Record name: _ldap._tcp
  SRV record: 0 100 389 jetfire

  Record name: _ntp._udp
  SRV record: 0 100 123 jetfire

  Record name: jetfire
  AAAA record: 2620:52:0:41c9:5054:ff:fea8:b669

  Record name: ratchet
  AAAA record: fe80::5054:ff:fea6:ec8, 2620:52:0:41c9:5054:ff:fea6:ec8
-----------------------------
Number of entries returned 12
-----------------------------


[root@ratchet ~]# nslookup -type=AAAA ratchet.lab.eng.pnq.redhat.com
Server:		2620:52:0:41c9:5054:ff:fea8:b669
Address:	2620:52:0:41c9:5054:ff:fea8:b669#53

ratchet.lab.eng.pnq.redhat.com	has AAAA address fe80::5054:ff:fea6:ec8
ratchet.lab.eng.pnq.redhat.com	has AAAA address 2620:52:0:41c9:5054:ff:fea6:ec8

Verified.
# rpm -qi sssd | head
Name        : sssd                         Relocations: (not relocatable)
Version     : 1.5.1                             Vendor: Red Hat, Inc.
Release     : 53.el6                        Build Date: Fri 30 Sep 2011 10:10:28 AM EDT
Install Date: Mon 03 Oct 2011 08:54:42 AM EDT      Build Host: hs20-bc2-3.build.redhat.com
Group       : Applications/System           Source RPM: sssd-1.5.1-53.el6.src.rpm
Size        : 3551489                          License: GPLv3+
Signature   : (none)
Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
URL         : http://fedorahosted.org/sssd/
Summary     : System Security Services Daemon

Comment 4 Jakub Hrozek 2011-10-27 15:45:28 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Cause: The buffer used by the dynamic DNS update code was not big enough to contain IPv6 addresses
Consequence: Only part of the address was written into DNS, mangling the records
Fix: A larger buffer that is able to contain all address families is used
Result: dynamic DNS updates work correctly in an IPv6 environment

Comment 5 errata-xmlrpc 2011-12-06 16:39:00 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1529.html


Note You need to log in before you can comment on or make changes to this bug.