Lines Matching refs:name

3  * DNS - host name to IP address resolver.
8 * Implements a DNS host name to IP address resolver.
10 * The lwIP DNS resolver functions are used to lookup a host name and
18 * gethostbyname() then does a dns_lookup() to see if the name is
56 * 3. The name of the author may not be used to endorse or promote
195 /* DNS query record starts with either a domain name or a pointer
196 to a name already present somewhere in the packet. */
205 /* DNS answer record starts with either a domain name or a pointer
206 to a name already present somewhere in the packet. */
237 char name[DNS_MAX_NAME_LENGTH];
265 * external name resolution is performed */
447 LWIP_ASSERT("invalid host name (NULL)", init_entry->name != NULL);
448 namelen = strlen(init_entry->name);
454 MEMCPY(entry_name, init_entry->name, namelen);
456 entry->name = entry_name;
482 iterator_fn(entry->name, &entry->addr, iterator_arg);
490 iterator_fn(local_hostlist_static[i].name, &local_hostlist_static[i].addr, iterator_arg);
524 if ((lwip_stricmp(entry->name, hostname) == 0) &&
536 if ((lwip_stricmp(local_hostlist_static[i].name, hostname) == 0) &&
566 if (((hostname == NULL) || !lwip_stricmp(entry->name, hostname)) &&
601 LWIP_ASSERT("invalid host name (NULL)", hostname != NULL);
611 entry->name = entry_name;
629 * @param name the hostname to look up
636 dns_lookup(const char *name, ip_addr_t *addr LWIP_DNS_ADDRTYPE_ARG(u8_t dns_addrtype))
640 if (dns_lookup_local(name, addr LWIP_DNS_ADDRTYPE_ARG(dns_addrtype)) == ERR_OK) {
645 if (DNS_LOOKUP_LOCAL_EXTERN(name, addr, LWIP_DNS_ADDRTYPE_ARG_OR_ZERO(dns_addrtype)) == ERR_OK) {
650 /* Walk through name list, return entry if found. If not, return NULL. */
653 (lwip_strnicmp(name, dns_table[i].name, sizeof(dns_table[i].name)) == 0) &&
655 LWIP_DEBUGF(DNS_DEBUG, ("dns_lookup: \"%s\": found = ", name));
669 * Compare the "dotted" name "query" with the encoded name "response"
681 * @param start_offset offset into p where the name starts
682 * @return 0xFFFF: names differ, other: names equal -> offset behind name
699 /* Compressed name: cannot be equal since we don't send them */
702 /* Not compressed name */
735 * Walk through a compact encoded DNS name and return the end of the name.
737 * @param p pbuf containing the name
738 * @param query_idx start index into p pointing to encoded DNS name in the DNS server response
739 * @return index to end of the name
754 /* Compressed name: since we only want to skip it (not check it), stop here */
757 /* Not compressed name */
795 (u16_t)(entry->server_idx), entry->name));
814 (u16_t)(sizeof(udp_data) + SIZEOF_DNS_HDR + strlen(entry->name) + 2 + SIZEOF_DNS_QUERY), PBUF_RAM);
816 p = pbuf_alloc(PBUF_TRANSPORT, (u16_t)(SIZEOF_DNS_HDR + strlen(entry->name) + 2 + SIZEOF_DNS_QUERY), PBUF_RAM);
819 p = pbuf_alloc(PBUF_TRANSPORT, (u16_t)(SIZEOF_DNS_HDR + strlen(entry->name) + 2 +
853 hostname = entry->name;
899 LWIP_DEBUGF(DNS_DEBUG, ("sending DNS request ID %d for name \"%s\" to server %d\r\n",
900 entry->txid, entry->name, entry->server_idx));
1057 (*dns_requests[i].found)(dns_table[idx].name, addr, dns_requests[i].arg);
1064 (*dns_requests[idx].found)(dns_table[idx].name, addr, dns_requests[idx].arg);
1176 LWIP_DEBUGF(DNS_DEBUG, ("dns_check_entry: \"%s\": timeout\n", entry->name));
1199 LWIP_DEBUGF(DNS_DEBUG, ("dns_check_entry: \"%s\": flush\n", entry->name));
1236 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": response = ", entry->name));
1286 /* Match the ID in the DNS header with the name table. */
1300 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": not a response\n", entry->name));
1304 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": response not match to query\n", entry->name));
1338 /* Check if the name in the "question" part match with the name in the entry and
1340 res_idx = dns_compare_name(entry->name, p, SIZEOF_DNS_HDR);
1342 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": response not match to query\n", entry->name));
1353 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": response not match to query\n", entry->name));
1364 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": error in flags\n", entry->name));
1381 /* skip answer resource record's host name */
1460 LWIP_DEBUGF(DNS_DEBUG, ("dns_recv: \"%s\": error in response\n", entry->name));
1480 * @param name the hostname that is to be queried
1487 dns_enqueue(const char *name, size_t hostnamelen, dns_found_callback found,
1501 (lwip_strnicmp(name, dns_table[i].name, sizeof(dns_table[i].name)) == 0)) {
1517 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": duplicate request\n", name));
1549 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": DNS entries table is full\n", name));
1569 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": DNS request entries table is full\n", name));
1579 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": use DNS entry %"U16_F"\n", name, (u16_t)(i)));
1589 MEMCPY(entry->name, name, namelen);
1590 entry->name[namelen] = 0;
1596 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": failed to allocate a pcb\n", name));
1601 LWIP_DEBUGF(DNS_DEBUG, ("dns_enqueue: \"%s\": use DNS pcb %"U16_F"\n", name, (u16_t)(entry->pcb_idx)));
1624 * name is already in the local names table.
1679 LWIP_DEBUGF(DNS_DEBUG, ("dns_gethostbyname: name too long to resolve"));
1691 /* host name already in octet notation? set ip addr and return ERR_OK */