lwIP - A Lightweight TCP/IP stack - Tasks: task #7017, Implement DNS client
You are not allowed to post comments on this tracker with your current authentication level.
task #7017: Implement DNS client
Submitter: | Frédéric Bernon <fbernon> | ||
Submitted: | Tue 19 Jun 2007 12:37:35 PM UTC | ||
Category: | None | Should Start On: | Mon 18 Jun 2007 10:00:00 PM UTC |
Should be Finished on: | Tue 18 Dec 2007 05:00:00 AM UTC | Priority: | 5 - Normal |
Status: | Done | Privacy: | Public |
Assigned to: | jim_pettinato | Percent Complete: | 100% |
Open/Closed: | Closed | Planned Release: | 1.3.0 |
Effort: | 0.00 |
Jump to the original submission
Fri 14 Dec 2007 09:03:50 PM UTC, comment #100: |
Frédéric Bernon <fbernon> |
Thu 13 Dec 2007 11:07:53 PM UTC, comment #99: Done, but could need more tests (but I think it's good).
|
Frédéric Bernon <fbernon> |
Thu 13 Dec 2007 07:11:38 AM UTC, comment #98: Fine for me! |
Simon Goldschmidt <goldsimon> |
Wed 12 Dec 2007 11:11:44 PM UTC, comment #97: DNS_ERR_MEM => ERR_MEM
|
Frédéric Bernon <fbernon> |
Wed 12 Dec 2007 07:24:41 PM UTC, comment #96: I moved DNS_MSG_SIZE in opt.h, and add a comment, like jifl suggests it.
|
Frédéric Bernon <fbernon> |
Wed 12 Dec 2007 06:32:47 PM UTC, comment #95:
|
Jonathan Larmour <jifl> |
Wed 12 Dec 2007 06:03:45 PM UTC, comment #94:
|
Frédéric Bernon <fbernon> |
Tue 11 Dec 2007 10:19:27 PM UTC, comment #93: I think DNS_MSG_SIZE should go in opt.h as well as it has a direct effect on memory use.
|
Jonathan Larmour <jifl> |
Tue 11 Dec 2007 08:03:54 PM UTC, comment #92: My suggestions:
|
Simon Goldschmidt <goldsimon> |
Tue 11 Dec 2007 07:58:26 PM UTC, comment #91: Yes, it's done. The last thing to do is to choose where to place DNS options (see comment #61). |
Frédéric Bernon <fbernon> |
Tue 11 Dec 2007 07:47:46 PM UTC, comment #90: Re comment #76:
|
Simon Goldschmidt <goldsimon> |
Wed 05 Dec 2007 12:16:44 AM UTC, comment #89: The patch looks fine to me.
|
Jonathan Larmour <jifl> |
Tue 04 Dec 2007 10:35:45 PM UTC, comment #88: Here the patch for static or per-thread variables set for "gethostbyname". Is it ok for you?
|
Frédéric Bernon <fbernon> |
Tue 04 Dec 2007 10:13:53 PM UTC, comment #87:
|
Frédéric Bernon <fbernon> |
Tue 04 Dec 2007 12:09:39 PM UTC, comment #86: Re LWIP_MAKE_ADDRWORD - a helper macro would be useful and easy to provide. From David's comment, it looks like it would want to be:
|
Jonathan Larmour <jifl> |
Mon 03 Dec 2007 09:19:39 PM UTC, comment #85: Just a comment regarding the proposed LWIP_MAKE_ADDRWORD macro or equivalent expression: it would be handy if this was written in a way which allows it to be used on a compiler for a 16-bit processor without having to modify core LWIP source code.
|
David Empson <dempson> |
Mon 03 Dec 2007 06:08:30 PM UTC, comment #84: To be honest, except "localhost", I don't see any real cases where a hardcoded name could be useful. Can you tell me some samples for such uses?
|
Frédéric Bernon <fbernon> |
Mon 03 Dec 2007 04:55:17 PM UTC, comment #83: I like that thought! Maybe we could add a macro like
|
Simon Goldschmidt <goldsimon> |
Sun 02 Dec 2007 10:35:18 PM UTC, comment #82: Strictly it's incorrect: the name localhost is not special, and the configured DNS server should map it to 127.0.0.1 anyway. In practice it makes sense though :).
|
Jonathan Larmour <jifl> |
Sat 01 Dec 2007 01:04:45 PM UTC, comment #81: That's OK I think. Even if someone changes the address of the loopif, localhost should translate to 127.0.0.1, shouldn't it? |
Simon Goldschmidt <goldsimon> |
Sat 01 Dec 2007 10:27:17 AM UTC, comment #80: Are you agree to add in dns_gethostbyname this code :
|
Frédéric Bernon <fbernon> |
Fri 30 Nov 2007 03:24:41 PM UTC, comment #79: For what it's worth I agree with Frédéric.
|
Jonathan Larmour <jifl> |
Fri 30 Nov 2007 02:30:11 PM UTC, comment #78:
|
Frédéric Bernon <fbernon> |
Fri 30 Nov 2007 02:17:23 PM UTC, comment #77: I would like to move the creation of the udp pcb dns uses from dns_init to a function called the first time dns_gethostbyname so the pcb isn't created until it is really used. |
Simon Goldschmidt <goldsimon> |
Thu 29 Nov 2007 09:20:07 AM UTC, comment #76: I hope (again) find time this weekend for a "per-thread/static" option.
|
Frédéric Bernon <fbernon> |
Thu 29 Nov 2007 07:53:23 AM UTC, comment #75: DNS seems pretty complete. Can we close this or is there something left? |
Simon Goldschmidt <goldsimon> |
Thu 22 Nov 2007 06:51:15 PM UTC, comment #74: re comment #41:
|
Simon Goldschmidt <goldsimon> |
Thu 22 Nov 2007 01:17:37 PM UTC, comment #73: I think you may as well keep the other RR type defines in, since I think being able to query those is important and we should do it. But I also agree it can wait until after 1.3.0. For example, I'm not sure how Frederic proposes it would work would be right - not every lookup should recurse all the way to an IP address.
|
Jonathan Larmour <jifl> |
Thu 22 Nov 2007 08:26:16 AM UTC, comment #72:
|
Frédéric Bernon <fbernon> |
Thu 22 Nov 2007 08:09:38 AM UTC, comment #71:
|
Simon Goldschmidt <goldsimon> |
Wed 21 Nov 2007 07:41:46 PM UTC, comment #70:
|
Frédéric Bernon <fbernon> |
Wed 21 Nov 2007 06:32:01 PM UTC, comment #69:
|
Simon Goldschmidt <goldsimon> |
Wed 21 Nov 2007 06:16:15 PM UTC, comment #68: As long the linker can drop the code if the application doesn't use it, it's not a problem to add it.
|
Frédéric Bernon <fbernon> |
Wed 21 Nov 2007 06:03:36 PM UTC, comment #67: Does anyone care for a thread-safe implementation of getaddrinfo/freeaddrinfo (the official successor of gethostbyname, which is not thread-safe)?
|
Simon Goldschmidt <goldsimon> |
Tue 20 Nov 2007 10:00:32 PM UTC, comment #66: I hope do my last changes on DNS (for a static/per-thread set of variables for hostent) this weekend.
|
Frédéric Bernon <fbernon> |
Tue 20 Nov 2007 09:58:25 PM UTC, comment #65: Perhaps I'm wrong but it seems it's "h_errno", and not "errno" we should set on error :
|
Frédéric Bernon <fbernon> |
Tue 20 Nov 2007 09:48:02 PM UTC, comment #64:
|
Frédéric Bernon <fbernon> |
Tue 20 Nov 2007 08:32:04 PM UTC, comment #63: The new code works fine!
|
Simon Goldschmidt <goldsimon> |
Tue 20 Nov 2007 09:17:01 AM UTC, comment #62:
|
Frédéric Bernon <fbernon> |
Tue 20 Nov 2007 08:57:56 AM UTC, comment #61:
|
Frédéric Bernon <fbernon> |
Tue 20 Nov 2007 07:24:15 AM UTC, comment #60:
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 10:50:32 PM UTC, comment #59: Ok, it's check in, hoping it is what you expected.
|
Frédéric Bernon <fbernon> |
Mon 19 Nov 2007 09:16:21 PM UTC, comment #58:
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 08:37:05 PM UTC, comment #57:
|
Jim Pettinato <jim_pettinato> |
Mon 19 Nov 2007 08:30:45 PM UTC, comment #56:
|
Frédéric Bernon <fbernon> |
Mon 19 Nov 2007 08:27:19 PM UTC, comment #55:
and
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 08:06:33 PM UTC, comment #54: I'm already working on most of these problems. I think most will be check in this evening. So, please, wait until "tomorrow" (I'm on IRC if you want to chat)...
|
Frédéric Bernon <fbernon> |
Mon 19 Nov 2007 08:00:10 PM UTC, comment #53:
|
Jim Pettinato <jim_pettinato> |
Mon 19 Nov 2007 07:42:03 PM UTC, comment #52:
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 07:34:21 PM UTC, comment #51: Uhhm, hust a question, but has anyone really stress-tested this DNS client? I just did and discovered some issues. Since this is not really my code, I'm posting them here (although I'm happy to change the code if you let me ;-)
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 07:00:51 PM UTC, comment #50:
|
Frédéric Bernon <fbernon> |
Mon 19 Nov 2007 06:51:49 PM UTC, comment #49: I'm not familiar with the layout/structs dns uses to address the buffer the pbuf points to, but I guess coping with a split response will be very difficult, so we have to copy the response somewhere.
|
Simon Goldschmidt <goldsimon> |
Mon 19 Nov 2007 05:40:55 PM UTC, comment #48:
|
Frédéric Bernon <fbernon> |
Mon 19 Nov 2007 04:46:46 PM UTC, comment #47: Thanks Frédéric and Simon for all your work on this... looks great to me.
|
Jim Pettinato <jim_pettinato> |
Sun 18 Nov 2007 09:32:11 PM UTC, comment #46: Changes for comments #23,24,25 are done. It's also compliant with "RFC1035 - 7.3. Processing responses".
|
Frédéric Bernon <fbernon> |
Sun 18 Nov 2007 08:55:25 PM UTC, comment #45: Ok, I have check in a change for this problem. |
Frédéric Bernon <fbernon> |
Sun 18 Nov 2007 08:35:00 PM UTC, comment #44: About comment #42, what I want to say is this problem only appears with "large" responses, so, perhaps it's not a problem for lot of users.
|
Frédéric Bernon <fbernon> |
Sun 18 Nov 2007 08:06:41 PM UTC, comment #43:
|
Simon Goldschmidt <goldsimon> |
Sun 18 Nov 2007 07:45:32 PM UTC, comment #42:
|
Simon Goldschmidt <goldsimon> |
Sun 18 Nov 2007 06:51:23 PM UTC, comment #41: I have add an assert if the recv DNS response doesn't fit in one pbuf. I also add a sanity check warning to see if PBUF_POOL_BUFSIZE is large enough (of course, we could receive another kind of pbuf, but it should be good for most of cases).
|
Frédéric Bernon <fbernon> |
Sun 18 Nov 2007 04:36:59 PM UTC, comment #40:
Why not?
Not so useful. But we can.
|
Frédéric Bernon <fbernon> |
Sun 18 Nov 2007 01:31:00 PM UTC, comment #39: Some more todos:
|
Simon Goldschmidt <goldsimon> |
Sun 18 Nov 2007 10:15:18 AM UTC, comment #38:
|
Simon Goldschmidt <goldsimon> |
Sat 17 Nov 2007 01:22:37 PM UTC, comment #37: Ok, last changes are good for me. I'm happy you have used a specific struct for do_gethostbyname, it will be better if one day, we want to add more fields (aliases, more ip addresses...).
|
Frédéric Bernon <fbernon> |
Fri 16 Nov 2007 08:27:58 AM UTC, comment #36:
|
Frédéric Bernon <fbernon> |
Fri 16 Nov 2007 07:17:12 AM UTC, comment #35:
|
Simon Goldschmidt <goldsimon> |
Thu 15 Nov 2007 10:45:31 PM UTC, comment #34: Good job ! Only some details to see:
|
Frédéric Bernon <fbernon> |
Thu 15 Nov 2007 09:09:42 PM UTC, comment #33: ... and please ignore the wrong or missing comments :-) |
Simon Goldschmidt <goldsimon> |
Thu 15 Nov 2007 09:07:28 PM UTC, comment #32: I've created a function netconn_gethostbyname (in api_lib.c), do_gethostbyname(in api_msg.c) and gethostbyname (in sockets.c, using netconn_gethostbyname).
|
Simon Goldschmidt <goldsimon> |
Thu 15 Nov 2007 08:14:24 PM UTC, comment #31: Can we convert all the function parameters char* hostname into const chars?
|
Simon Goldschmidt <goldsimon> |
Thu 15 Nov 2007 09:29:53 AM UTC, comment #30: Simon wrote :
|
Frédéric Bernon <fbernon> |
Thu 15 Nov 2007 09:04:15 AM UTC, comment #29:
|
Frédéric Bernon <fbernon> |
Thu 15 Nov 2007 03:44:49 AM UTC, comment #28: Unfortunately per-thread info isn't really sensible here - it is not just the struct hostent that needs to be per-thread, but the contents of all the pointers it points to.
|
Jonathan Larmour <jifl> |
Wed 14 Nov 2007 11:46:58 PM UTC, comment #27: Ok, dns client is check in. "msvc6" port is updated to test it. The "todo list" is updated. We can also thought to sequential api. The main problem is how to provide a safe-thread function :
|
Frédéric Bernon <fbernon> |
Wed 14 Nov 2007 09:13:33 PM UTC, comment #26: About comment #22, since there is no objections, I will add dns files this evening. |
Frédéric Bernon <fbernon> |
Tue 13 Nov 2007 09:03:24 PM UTC, comment #25: From RFC2181, section 8, page 10:
|
Jonathan Larmour <jifl> |
Tue 13 Nov 2007 08:51:19 PM UTC, comment #24:
|
Frédéric Bernon <fbernon> |
Tue 13 Nov 2007 08:25:27 PM UTC, comment #23: From RFC 1035 (DNS):
|
Jim Pettinato <jim_pettinato> |
Tue 13 Nov 2007 08:12:16 PM UTC, comment #22: Is there any objections to add dns files in 1.3.0 ?
|
Frédéric Bernon <fbernon> |
Tue 13 Nov 2007 08:07:51 PM UTC, comment #21:
|
Frédéric Bernon <fbernon> |
Tue 13 Nov 2007 06:34:04 PM UTC, comment #20:
|
Jim Pettinato <jim_pettinato> |
Tue 13 Nov 2007 02:22:55 PM UTC, comment #19:
|
Frédéric Bernon <fbernon> |
Tue 13 Nov 2007 01:48:22 PM UTC, comment #18:
|
Jim Pettinato <jim_pettinato> |
Tue 13 Nov 2007 12:48:46 AM UTC, comment #17: Hi Jim,
|
Frédéric Bernon <fbernon> |
Fri 02 Nov 2007 06:21:53 PM UTC, comment #16: Hi Jim,
|
Frédéric Bernon <fbernon> |
Mon 16 Jul 2007 09:36:27 PM UTC, comment #15:
|
Jim Pettinato <jim_pettinato> |
Mon 16 Jul 2007 01:36:02 PM UTC, comment #14:
|
Jim Pettinato <jim_pettinato> |
Sat 14 Jul 2007 08:17:24 AM UTC, comment #13: (Winformatik Info wrote)
|
Frédéric Bernon <fbernon> |
Thu 28 Jun 2007 07:54:53 AM UTC, comment #12:
|
Frédéric Bernon <fbernon> |
Thu 28 Jun 2007 06:26:01 AM UTC, comment #11:
|
Simon Goldschmidt <goldsimon> |
Wed 27 Jun 2007 07:27:16 PM UTC, comment #10:
|
Jim Pettinato <jim_pettinato> |
Wed 20 Jun 2007 12:17:08 PM UTC, comment #9: (answers from Jim)
|
Frédéric Bernon <fbernon> |
Wed 20 Jun 2007 11:05:44 AM UTC, comment #8: Some other remarks for integration:
|
Frédéric Bernon <fbernon> |
Wed 20 Jun 2007 08:56:12 AM UTC, comment #7: You're right about resolv, but "dns" seems more clear than "resolv".
|
Frédéric Bernon <fbernon> |
Tue 19 Jun 2007 03:14:51 PM UTC, comment #6:
|
Simon Goldschmidt <goldsimon> |
Tue 19 Jun 2007 02:58:34 PM UTC, comment #5: Agreed with Frédéric on the naming question. |
Kieran Mansley <kieranm> |
Tue 19 Jun 2007 02:27:22 PM UTC, comment #4:
|
Frédéric Bernon <fbernon> |
Tue 19 Jun 2007 02:22:27 PM UTC, comment #3: Jim Pettinato wrote:
|
Simon Goldschmidt <goldsimon> |
Tue 19 Jun 2007 01:41:29 PM UTC, comment #2: dns_gethostbyname for raw api and keep gethostbyname for socket layer, and netconn_gethostbyname for netconn layer ?
|
Frédéric Bernon <fbernon> |
Tue 19 Jun 2007 01:10:16 PM UTC, comment #1: I'd change the function name gethostbyname() to something else for RAW api and create other (blocking) functions that can be used in sequential socket api applications, only to be more compatible to other gethostbyname functions. |
Simon Goldschmidt <goldsimon> |
Tue 19 Jun 2007 12:37:35 PM UTC, original submission:
Several users ask for a DNS client to get functions like "gethostbyname".
|
Frédéric Bernon <fbernon> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 16 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2007-12-15 | fbernon | Status | In Progress | Done | |
Percent Complete | 90% | 100% | |||
Open/Closed | Open | Closed | |||
2007-12-04 | fbernon | Attached File | - | Added netdb.patch, #14560 | |
2007-11-19 | jim_pettinato | Should be Finished on | 2007-06-18 | 2007-12-18 | |
2007-11-15 | goldsimon | Attached File | - | Added dns_api.patch, #14408 | |
2007-11-14 | fbernon | Percent Complete | 80% | 90% | |
Planned Release | None | 1.3.0 | |||
2007-11-13 | jim_pettinato | Priority | 3 - Low | 5 - Normal | |
Status | None | In Progress | |||
Percent Complete | 10% | 80% | |||
2007-11-13 | fbernon | Attached File | - | Added dns.c, #14372 | |
Attached File | - | Added dns.h, #14373 | |||
Percent Complete | 0% | 10% | |||
2007-07-16 | jim_pettinato | Assigned to | None | jim_pettinato | |
2007-06-19 | fbernon | Attached File | - | Added dns.c, #13103 |
Powered by Savane 3.13-4448.
Corresponding source code
I note some possible improvements for a future task:
- return multiple ip addresses
- return other RR types (MX, SRV...)
- implement a "dynamic dns update" message
Jim, no objections to close this task ?