mDNS client (Multicast DNS) More...
#include "core/net.h"
#include "core/socket.h"
#include "core/udp.h"
#include "dns/dns_cache.h"
#include "dns/dns_common.h"
Go to the source code of this file.
Macros | |
#define | MDNS_CLIENT_SUPPORT DISABLED |
#define | MDNS_CLIENT_MAX_RETRIES 3 |
#define | MDNS_CLIENT_INIT_TIMEOUT 1000 |
#define | MDNS_CLIENT_MAX_TIMEOUT 1000 |
#define | MDNS_MAX_LIFETIME 60000 |
#define | MDNS_ADDITIONAL_RECORDS_SUPPORT ENABLED |
Functions | |
error_t | mdnsClientResolve (NetInterface *interface, const char_t *name, HostType type, IpAddr *ipAddr) |
Resolve a host name using mDNS. More... | |
error_t | mdnsClientSendQuery (DnsCacheEntry *entry) |
Send a mDNS query message. More... | |
void | mdnsClientParseAnRecord (NetInterface *interface, const MdnsMessage *message, size_t offset, const DnsResourceRecord *record) |
Parse a resource record from the Answer Section. More... | |
Detailed Description
mDNS client (Multicast DNS)
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneTCP Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- Version
- 2.4.4
Definition in file mdns_client.h.
Macro Definition Documentation
◆ MDNS_ADDITIONAL_RECORDS_SUPPORT
#define MDNS_ADDITIONAL_RECORDS_SUPPORT ENABLED |
Definition at line 78 of file mdns_client.h.
◆ MDNS_CLIENT_INIT_TIMEOUT
#define MDNS_CLIENT_INIT_TIMEOUT 1000 |
Definition at line 57 of file mdns_client.h.
◆ MDNS_CLIENT_MAX_RETRIES
#define MDNS_CLIENT_MAX_RETRIES 3 |
Definition at line 50 of file mdns_client.h.
◆ MDNS_CLIENT_MAX_TIMEOUT
#define MDNS_CLIENT_MAX_TIMEOUT 1000 |
Definition at line 64 of file mdns_client.h.
◆ MDNS_CLIENT_SUPPORT
#define MDNS_CLIENT_SUPPORT DISABLED |
Definition at line 43 of file mdns_client.h.
◆ MDNS_MAX_LIFETIME
#define MDNS_MAX_LIFETIME 60000 |
Definition at line 71 of file mdns_client.h.
Function Documentation
◆ mdnsClientParseAnRecord()
void mdnsClientParseAnRecord | ( | NetInterface * | interface, |
const MdnsMessage * | message, | ||
size_t | offset, | ||
const DnsResourceRecord * | record | ||
) |
Parse a resource record from the Answer Section.
- Parameters
-
[in] interface Underlying network interface [in] message Pointer to the mDNS message [in] offset Offset to first byte of the resource record [in] record Pointer to the resource record
Definition at line 257 of file mdns_client.c.
◆ mdnsClientResolve()
error_t mdnsClientResolve | ( | NetInterface * | interface, |
const char_t * | name, | ||
HostType | type, | ||
IpAddr * | ipAddr | ||
) |
Resolve a host name using mDNS.
- Parameters
-
[in] interface Underlying network interface [in] name Name of the host to be resolved [in] type Host type (IPv4 or IPv6) [out] ipAddr IP address corresponding to the specified host name
Definition at line 55 of file mdns_client.c.
◆ mdnsClientSendQuery()
error_t mdnsClientSendQuery | ( | DnsCacheEntry * | entry | ) |
Send a mDNS query message.
- Parameters
-
[in] entry Pointer to a valid DNS cache entry
- Returns
- Error code
Definition at line 196 of file mdns_client.c.