Open
Bug 735967
Opened 13 years ago
Updated 2 years ago
DNS: Prepare nsHostResolver and nsDNSService to use different record types
Categories
(Core :: Networking: DNS, defect, P3)
Core
Networking: DNS
Tracking
()
NEW
People
(Reporter: sworkman, Unassigned)
References
Details
(Whiteboard: [necko-backlog])
Attachments
(2 files)
41.93 KB,
patch
|
Details | Diff | Splinter Review | |
18.86 KB,
patch
|
Details | Diff | Splinter Review |
Hostname resolver currently supports A and AAAA resource record types only. Bug 14328 and bug 545866 have patches to support SRV, MX, NAPTR and TXT. However, an underlying framework which uses the existing threadpool and cache is desired.
Reporter | ||
Updated•13 years ago
|
Attachment #606078 -
Attachment is patch: true
Reporter | ||
Comment 1•13 years ago
|
||
Reporter | ||
Comment 2•13 years ago
|
||
I've uploaded a couple of WIP patches for feedback on the general approach taken. The nsHostResolver one is more complete, but definitely needs polish. Both together should provide a framework with which we can use code from Bug 14328 and Bug 545866 to get those extra DNS resource record types, while using the current threadpool and DNS cache.
The main changes in nsHostResolver is that the nsHostRecord sub-classes now take ownership of the resolver function. This means that in nsHostResolver::ThreadFunc, a call is made to nsHostRecord::Lookup, which is a virtual function implemented by nsHostRecordTypeA|TypeSRV|TypeMX|TypeNAPTR sub-classes.
I'm thinking that this might be suitable for DNSSec queries later, i.e. having something like nsHostRecordTypeA making a standard query and nsHostRecordTypeASec making a DNSSec query. Motive at the moment would just be to separate out the functionality, possibly for a phased introduction of DNSSec (or whatever) in our code.
Re the nsDNSService patch, I've included IDL interfaces nsIDNSSRV|MX|NAPTRRecord, but they might not be needed - the nsIDNSTypeRecord interface may be sufficient along with nsIDNSSRV|MX|NAPTRRecordEntry interfaces. This patch is very high level at present, but hopefully it should be enough to cast a vision of the framework.
(Note: I'm still not working on this as top priority, but I wanted to develop the idea in parallel to my other work).
Comment 3•13 years ago
|
||
Steve,
Thanks for working on this! I've been getting behind-the-scenes pings from many of the XMPP folk who are working in XMPP related js code that would love to see this class of problem be fixed in Mozilla Core
Please do let me know if there is anything I can do to help
Reporter | ||
Comment 4•13 years ago
|
||
Thanks, Mike.
Someone information to add to the proposed approach. We needed to confirm that res_query could be exposed on Android, which it seems like it can. We package some of the Android libc code, specifically an implementation of getaddrinfo, in order to get threadsafe functionality on pre-Honeycomb/v3.0 devices. res_query is not normally exposed in the Android NDK, but since we package it, that is under our control.
We can also restrict res_query to be called only for non-A/AAAA types. Currently, we restrict the packaged getaddrinfo to pre-Honeycomb calls only, and we can maintain that: i.e. A/AAAA requests would use the current method. But, we'd have to expose and use res_query on all Android versions to get access to rr types on those devices.
Not a huge issues per se, but important to point out that it needs to work across all of our supported platforms.
Assignee: nobody → sworkman
Comment 5•13 years ago
|
||
Steve, thanks for working on this!
FWIW, my patch in bug 545866 was based on the patch in bug 14328. I see you didn't make any IDL changes yet. If you could take a look and use the IDL changes I made (and the 5 code changes that are made necessary by that), that'd be great. I actually only cared that the IDL interface is clean and generic for all types (including A), because that's what apps have to use.
Comment 6•13 years ago
|
||
Steve,
With the merge happening next week is there anything we can do to hit that window? or start preparing for the next?
thanks!
Reporter | ||
Comment 7•13 years ago
|
||
Hi Mike,
I'm sorry but I don't think hitting next week is likely. My hands are pretty full at the moment with DASH, and (unfortunately for this bug) that's my top priority. I think aiming for the next release is a more achievable goal.
Comment 8•13 years ago
|
||
Steve,
thanks for the reply, I will try again next merge week :)
Comment 9•12 years ago
|
||
Steve,
Is there any hope of seeing things move forward here in the foreseeable future?
Blocks: 787369
Updated•9 years ago
|
Assignee: sworkman → nobody
Whiteboard: [necko-backlog]
Comment 10•8 years ago
|
||
Bulk change to priority: https://bugzilla.mozilla.org/show_bug.cgi?id=1399258
Priority: -- → P1
Comment 11•8 years ago
|
||
Bulk change to priority: https://bugzilla.mozilla.org/show_bug.cgi?id=1399258
Priority: P1 → P3
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•