Menu

#9 Fixes for ALIAS handling in mydnscheck

open
nobody
None
5
2006-08-21
2006-08-21
No

[From mailing list]

Hi all,

I've found a few bugs in the mydnscheck code, to do
with ALIASes.

Firstly, when an alias exists at all mydnscheck will
throw an error
'non-CNAME record(s) present alongside CNAME'. This is
because
mydnscheck treats ALIAS records as CNAME records
internally, but
checks to see whether anything other than a CNAME
exists on a
particular name given a particular zone. It finds the
ALIAS and throws
an error.

Secondly, the handling of entries in the rr table that
have an empty
string for the 'name' column is broken (specifically,
the function
shortname() returns the entire domain when asked to
return only the
subdomain part of a record). This bug probably affects
all other
record types in addition to ALIAS records.

Thirdly (not sure if this is a bug), mydnscheck throws
the 'non-CNAME
record(s) present alongside CNAME' error when an MX
record exists
alongside an ALIAS, as in:

RR Table:
------------------------------
name type data
------------------------------
mail ALIAS www_server
mail MX mail_server

The mydns server itself appears to handle this
situation correctly, in
that it serves up the MX and the ALIAS. Is this a bug
in mydnscheck? I
think it is, but I haven't read the appropriate
specifications so I
could be wrong.

I've attached a patch against mydns-1.1.0 for (1) and
(2). (3) is
easily fixable, if it needs to be fixed :)

Cheers,
Patrick

Discussion

  • Patrick Coleman

    Patrick Coleman - 2006-08-21

    Patch to fix

     
  • Matus UHLAR - fantomas

    Logged In: YES
    user_id=933040

    well, I'm not sure the 2nd one is a bug, but I am sure the
    third one IS, as long as ALIAS is documented to be an
    alternative to CNAME which allows alongside records...
    could you split (and probably rename) this patch? Thank you.

     
  • Howard Wilkinson

    Logged In: YES
    user_id=655834
    Originator: NO

    As far as I can tell this patch has been incorporated into 1.2.7 can you please check.

    Also, I think the behaviour in case 3 is "correct" in that mydns currently serves whatever it finds in the database that it can understand, whereas the check routines tell you if the database is "correct". Hence we should get bad data if the check fails but no changes area made.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.