Hide Forgot
Description of problem: This was raised by atolani as part of IPA DNS Test day. When options are provided to dnsrecord-add and if any of the required option is missing, then the expected behaviour is to prompt for it interactively instead of displaying an error message. Similar to how we prompt for the zone name and record name if not provided in the command line. for example: [root@zetaprime ~]# ipa dnsrecord-add --sshfp-algorithm=1 --sshfp-fp-type=1 Zone name: lab.eng.pnq.redhat.com Record name: test44 ipa: ERROR: invalid 'sshfprecord': 'sshfp_fingerprint' is a required part of DNS record [root@zetaprime ~]# Here the user expected a interactive prompt asking for "sshfp_fingerprint" Version-Release number of selected component (if applicable): ipa-server-2.2.0-101.20120127T0607zgit6863b8f.el6.x86_64 How reproducible: Steps to Reproduce: 1. See description 2. 3. Actual results: Expected results: Additional info:
Upstream ticket: https://fedorahosted.org/freeipa/ticket/2386
fixed upstream: master: 1d09cdf6342cfd715c366e881ced1d1f22d1503a ipa-2-2: 104e9762375ac1d27fa0a853563b4de176d2fa8e LOC is another record type that is interesting to test. Also handles ^C and ^D.
[root@primenova ~]# ipa dnsrecord-add testrelm.com --sshfp-algorithm=2 Record name: sshfp SSHFP Fingerprint Type: 2 SSHFP Fingerprint: 8F3AFB98121C1DFF087E004A862D30B8935946D8, Record name: sshfp SSHFP record: 2 2 8F3AFB98121C1DFF087E004A862D30B8935946D8, [root@primenova ~]# This works as expected, however, while providing both --sshfp-algorithm and --sshfp-fp-type it asks for sshfp fingerprint multiple times. [root@primenova ~]# ipa dnsrecord-add --sshfp-algorithm=1 --sshfp-fp-type=1 Zone name: testrelm.com Record name: sshfp2 SSHFP Fingerprint: A69D7E3D53DB419FE43830956F08C0BC51431F89 <<<<<< SSHFP Fingerprint: 8F3AFB98121C1DFF087E004A862D30B8935946D8 <<<<<< Record name: sshfp2 SSHFP record: 1 1 8F3AFB98121C1DFF087E004A862D30B8935946D8 Tested in version: ipa-server-2.2.0-9.el6.x86_64
Good catch, I will open a ticket to fix it and send a patch today.
Upstream ticket: https://fedorahosted.org/freeipa/ticket/2641
Fixed interactive prompting upstream. master: 568de5027b9c7057e6f71cca4a45ced9ca7a7db6 ipa-2-2: 73b23bf21d0604cdc7c0b4a37011e01a17684faf
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: No documentation needed.
[root@primenova ~]# ipa dnsrecord-add --sshfp-algorithm=1 --sshfp-fp-type=1 Zone name: lab.eng.pnq.redhat.com Record name: test44 SSHFP Fingerprint: AF77D568A15C703DF5CEE89BFB76F0146DEA7586 Record name: test44 SSHFP record: 1 1 AF77D568A15C703DF5CEE89BFB76F0146DEA7586 [root@primenova ~]# [root@primenova ~]# ipa dnsrecord-add --sshfp-fp-type=1 Zone name: lab.eng.pnq.redhat.com Record name: test45 SSHFP Algorithm: 1 SSHFP Fingerprint: AF77D568A15C703DF5CEE89BFB76F0146DEA786 Record name: test45 SSHFP record: 1 1 AF77D568A15C703DF5CEE89BFB76F0146DEA786 [root@primenova ~]# [root@primenova ~]# ipa dnsrecord-add --sshfp-algorithm=1 --sshfp-fp-type=1 Zone name: lab.eng.pnq.redhat.com Record name: test46 SSHFP Fingerprint: AF77D568A15C703DF5CEE89BFB76F0146DEA7869 Record name: test46 SSHFP record: 1 1 AF77D568A15C703DF5CEE89BFB76F0146DEA7869 [root@primenova ~]#
[root@primenova ~]# ipa dnsrecord-add lab.eng.pnq.redhat.com --loc-lat-deg=49 --loc-lat-min=11 --loc-lat-sec=42.4 --loc-lat-dir=N --loc-lon-deg=16 Record name: test51 LOC Direction Longitude: E LOC Altitude: 123 Record name: test51 LOC record: 49 11 42.400 N 16 E 123.00 [root@primenova ~]# Verified: ipa-server-2.2.0-13.el6.x86_64
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-2012-0819.html