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 910460 - dnsrecord-* throws traceback if TXT record data contain ','
Summary: dnsrecord-* throws traceback if TXT record data contain ','
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: ipa
Version: 7.0
Hardware: Unspecified
OS: Unspecified
medium
unspecified
Target Milestone: rc
: ---
Assignee: Rob Crittenden
QA Contact: IDM QE LIST
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-12 17:18 UTC by Namita Soman
Modified: 2015-01-21 15:39 UTC (History)
2 users (show)

Fixed In Version: ipa-3.2.1-1.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-13 10:40:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Namita Soman 2013-02-12 17:18:14 UTC
This bug is created as a clone of upstream ticket:
https://fedorahosted.org/freeipa/ticket/3323

Try to add/delete/modify TXT record with comma and other strange characters in the data and you will see the traceback...

{{{
# ipa dnsrecord-add example.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said he.'
Traceback (most recent call last):
  File "/usr/bin/ipa", line 32, in <module>
    cli.run(api)
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1268, in run
    sys.exit(api.Backend.cli.run(argv))
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1049, in run
    kw = self.argv_to_keyword_arguments(cmd, argv[1:])
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1036, in argv_to_keyword_arguments
    kw = cmd.split_csv(**kw)
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in split_csv
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in <genexpr>
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 728, in split_csv
    for row in self.__unicode_csv_reader(lines):
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 697, in __unicode_csv_reader
    for row in csv_reader:
_csv.Error: newline inside string

# ipa dnsrecord-del example.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said he.'
Traceback (most recent call last):
  File "/usr/bin/ipa", line 32, in <module>
    cli.run(api)
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1268, in run
    sys.exit(api.Backend.cli.run(argv))
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1049, in run
    kw = self.argv_to_keyword_arguments(cmd, argv[1:])
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1036, in argv_to_keyword_arguments
    kw = cmd.split_csv(**kw)
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in split_csv
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in <genexpr>
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 728, in split_csv
    for row in self.__unicode_csv_reader(lines):
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 697, in __unicode_csv_reader
    for row in csv_reader:
_csv.Error: newline inside string

#  ipa dnsrecord-mod example.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said he.'
Traceback (most recent call last):
  File "/usr/bin/ipa", line 32, in <module>
    cli.run(api)
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1268, in run
    sys.exit(api.Backend.cli.run(argv))
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1049, in run
    kw = self.argv_to_keyword_arguments(cmd, argv[1:])
  File "/usr/lib/python2.6/site-packages/ipalib/cli.py", line 1036, in argv_to_keyword_arguments
    kw = cmd.split_csv(**kw)
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in split_csv
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 580, in <genexpr>
    (k, self.params[k].split_csv(v)) for (k, v) in kw.iteritems()
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 728, in split_csv
    for row in self.__unicode_csv_reader(lines):
  File "/usr/lib/python2.6/site-packages/ipalib/parameters.py", line 697, in __unicode_csv_reader
    for row in csv_reader:
_csv.Error: newline inside string
}}}

Comment 1 Namita Soman 2013-02-12 19:50:03 UTC
Upstream ticket:
https://fedorahosted.org/freeipa/ticket/3334

Comment 2 Rob Crittenden 2013-02-19 16:09:54 UTC
fixed upstream

master: cfbdeebe66c1759ba49da84a0a5d2acfc184e4f3

ipa-3-1: e7de41e4f00508602915e5142a0394da149a54dc

Comment 5 Xiyang Dong 2014-01-09 18:41:52 UTC
Verified:

[root@70master tests.d]# ipa dnsrecord-add testrelm.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said he.'
  Record name: @
  NS record: 70master.testrelm.com.
  TXT record: Holmes laughed. "It is quite a pretty little problem," said he.

[root@70master tests.d]# ipa dnsrecord-mod testrelm.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said me.'
  Record name: @
  NS record: 70master.testrelm.com.
  TXT record: Holmes laughed. "It is quite a pretty little problem," said me.

[root@70master tests.d]# ipa dnsrecord-del testrelm.com @ '--txt-rec=Holmes laughed. "It is quite a pretty little problem," said me.'
  Record name: @
  NS record: 70master.testrelm.com.

Comment 6 Ludek Smid 2014-06-13 10:40:12 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


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