9#ifndef __EFI_DNS_IMPL_H_
10#define __EFI_DNS_IMPL_H_
53#define DNS_VERSION 0x00000000
73#define DNS_SERVER_PORT 53
75#define DNS_PROTOCOL_UDP EFI_IP_PROTO_UDP
76#define DNS_PROTOCOL_TCP EFI_IP_PROTO_TCP
78#define DNS_STATE_UNCONFIGED 0
79#define DNS_STATE_CONFIGED 1
80#define DNS_STATE_DESTROY 2
82#define DNS_DEFAULT_TIMEOUT 2
84#define DNS_TIME_TO_GETMAP 5
111 UINT32 RetryCounting;
113 CHAR16 *QueryHostName;
115 BOOLEAN GeneralLookUp;
120 UINT32 RetryCounting;
122 CHAR16 *QueryHostName;
124 BOOLEAN GeneralLookUp;
142#define DNS_FLAGS_QR_QUERY 0
143#define DNS_FLAGS_QR_RESPONSE 1
145#define DNS_FLAGS_OPCODE_STANDARD 0
146#define DNS_FLAGS_OPCODE_INVERSE 1
147#define DNS_FLAGS_OPCODE_SERVER_STATE 2
149#define DNS_FLAGS_RCODE_NO_ERROR 0
150#define DNS_FLAGS_RCODE_NAME_ERROR 3
153 UINT16 Identification;
173#define DNS4_DOMAIN L"in-addr.arpa"
174#define DNS6_DOMAIN L"IP6.ARPA"
231 IN VOID *Arg OPTIONAL
255 IN VOID *Arg OPTIONAL
491 IN BOOLEAN DeleteFlag,
513 IN BOOLEAN DeleteFlag,
568 IN UINT16 Identification,
591 OUT BOOLEAN *Completed
891 IN BOOLEAN DeleteFlag,
1034 IN CHAR16 *HostName,
1139 IN BOOLEAN DeleteFlag,
1140 IN BOOLEAN Override,
EFI_STATUS EFIAPI Dns4Configure(IN EFI_DNS4_PROTOCOL *This, IN EFI_DNS4_CONFIG_DATA *DnsConfigData)
EFI_STATUS DoDnsQuery(IN DNS_INSTANCE *Instance, IN NET_BUF *Packet)
EFI_STATUS EFIAPI Dns6IpToHostName(IN EFI_DNS6_PROTOCOL *This, IN EFI_IPv6_ADDRESS IpAddress, IN EFI_DNS6_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI GetDns4TokenEntry(IN NET_MAP *TokensMap, IN EFI_DNS4_COMPLETION_TOKEN *Token, OUT DNS4_TOKEN_ENTRY **TokenEntry)
EFI_STATUS EFIAPI Dns4CancelTokens(IN NET_MAP *Map, IN NET_MAP_ITEM *Item, IN VOID *Arg OPTIONAL)
EFI_STATUS EFIAPI Dns6Cancel(IN EFI_DNS6_PROTOCOL *This, IN EFI_DNS6_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI Dns4Cancel(IN EFI_DNS4_PROTOCOL *This, IN EFI_DNS4_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI Dns4HostNameToIp(IN EFI_DNS4_PROTOCOL *This, IN CHAR16 *HostName, IN EFI_DNS4_COMPLETION_TOKEN *Token)
EFI_COMPONENT_NAME2_PROTOCOL gDnsComponentName2
EFI_STATUS DnsRetransmit(IN DNS_INSTANCE *Instance, IN NET_BUF *Packet)
EFI_STATUS EFIAPI Dns4UpdateDnsCache(IN EFI_DNS4_PROTOCOL *This, IN BOOLEAN DeleteFlag, IN BOOLEAN Override, IN EFI_DNS4_CACHE_ENTRY DnsCacheEntry)
EFI_STATUS EFIAPI Dns6Configure(IN EFI_DNS6_PROTOCOL *This, IN EFI_DNS6_CONFIG_DATA *DnsConfigData)
EFI_STATUS EFIAPI AddDns6ServerIp(IN LIST_ENTRY *Dns6ServerList, IN EFI_IPv6_ADDRESS ServerIp)
EFI_STATUS ConstructDNSQuery(IN DNS_INSTANCE *Instance, IN CHAR8 *QueryName, IN UINT16 Type, IN UINT16 Class, OUT NET_BUF **Packet)
EFI_STATUS Dns4InstanceCancelToken(IN DNS_INSTANCE *Instance, IN EFI_DNS4_COMPLETION_TOKEN *Token)
EFI_STATUS ParseDnsResponse(IN OUT DNS_INSTANCE *Instance, IN UINT8 *RxString, IN UINT32 Length, OUT BOOLEAN *Completed)
VOID Dns6CleanConfigure(IN OUT EFI_DNS6_CONFIG_DATA *Config)
EFI_STATUS Dns6InstanceCancelToken(IN DNS_INSTANCE *Instance, IN EFI_DNS6_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI Dns6UpdateDnsCache(IN EFI_DNS6_PROTOCOL *This, IN BOOLEAN DeleteFlag, IN BOOLEAN Override, IN EFI_DNS6_CACHE_ENTRY DnsCacheEntry)
EFI_STATUS Dns4CopyConfigure(OUT EFI_DNS4_CONFIG_DATA *Dst, IN EFI_DNS4_CONFIG_DATA *Src)
EFI_COMPONENT_NAME_PROTOCOL gDnsComponentName
EFI_STATUS EFIAPI AddDns4ServerIp(IN LIST_ENTRY *Dns4ServerList, IN EFI_IPv4_ADDRESS ServerIp)
EFI_STATUS Dns6CopyConfigure(OUT EFI_DNS6_CONFIG_DATA *Dst, IN EFI_DNS6_CONFIG_DATA *Src)
VOID EFIAPI DnsOnTimerUpdate(IN EFI_EVENT Event, IN VOID *Context)
VOID EFIAPI DnsOnPacketReceived(NET_BUF *Packet, UDP_END_POINT *EndPoint, EFI_STATUS IoStatus, VOID *Context)
EFI_STATUS Dns6RemoveTokenEntry(IN NET_MAP *TokenMap, IN DNS6_TOKEN_ENTRY *TokenEntry)
EFI_STATUS EFIAPI Dns6GetModeData(IN EFI_DNS6_PROTOCOL *This, OUT EFI_DNS6_MODE_DATA *DnsModeData)
EFI_STATUS Dns4ConfigUdp(IN DNS_INSTANCE *Instance, IN UDP_IO *UdpIo)
VOID EFIAPI DnsOnPacketSent(NET_BUF *Packet, UDP_END_POINT *EndPoint, EFI_STATUS IoStatus, VOID *Context)
VOID Dns4CleanConfigure(IN OUT EFI_DNS4_CONFIG_DATA *Config)
EFI_STATUS EFIAPI Dns6CancelTokens(IN NET_MAP *Map, IN NET_MAP_ITEM *Item, IN VOID *Arg OPTIONAL)
BOOLEAN Dns4GetMapping(IN DNS_INSTANCE *Instance, IN UDP_IO *UdpIo, IN EFI_UDP4_CONFIG_DATA *UdpCfgData)
EFI_STATUS EFIAPI Dns4Poll(IN EFI_DNS4_PROTOCOL *This)
VOID EFIAPI DnsDummyExtFree(IN VOID *Arg)
BOOLEAN IsValidDnsResponse(IN NET_MAP *TokensMap, IN UINT16 Identification, IN UINT16 Type, IN UINT16 Class, OUT NET_MAP_ITEM **Item)
EFI_STATUS EFIAPI Dns6HostNameToIp(IN EFI_DNS6_PROTOCOL *This, IN CHAR16 *HostName, IN EFI_DNS6_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI UpdateDns4Cache(IN LIST_ENTRY *Dns4CacheList, IN BOOLEAN DeleteFlag, IN BOOLEAN Override, IN EFI_DNS4_CACHE_ENTRY DnsCacheEntry)
EFI_STATUS EFIAPI Dns6Poll(IN EFI_DNS6_PROTOCOL *This)
EFI_STATUS EFIAPI UpdateDns6Cache(IN LIST_ENTRY *Dns6CacheList, IN BOOLEAN DeleteFlag, IN BOOLEAN Override, IN EFI_DNS6_CACHE_ENTRY DnsCacheEntry)
EFI_STATUS EFIAPI Dns4GeneralLookUp(IN EFI_DNS4_PROTOCOL *This, IN CHAR8 *QName, IN UINT16 QType, IN UINT16 QClass, IN EFI_DNS4_COMPLETION_TOKEN *Token)
EFI_STATUS Dns4RemoveTokenEntry(IN NET_MAP *TokenMap, IN DNS4_TOKEN_ENTRY *TokenEntry)
EFI_STATUS EFIAPI Dns4GetModeData(IN EFI_DNS4_PROTOCOL *This, OUT EFI_DNS4_MODE_DATA *DnsModeData)
VOID EFIAPI DnsOnTimerRetransmit(IN EFI_EVENT Event, IN VOID *Context)
EFI_STATUS EFIAPI Dns6GeneralLookUp(IN EFI_DNS6_PROTOCOL *This, IN CHAR8 *QName, IN UINT16 QType, IN UINT16 QClass, IN EFI_DNS6_COMPLETION_TOKEN *Token)
EFI_STATUS EFIAPI Dns4IpToHostName(IN EFI_DNS4_PROTOCOL *This, IN EFI_IPv4_ADDRESS IpAddress, IN EFI_DNS4_COMPLETION_TOKEN *Token)
BOOLEAN Dns6GetMapping(IN DNS_INSTANCE *Instance, IN UDP_IO *UdpIo, IN EFI_UDP6_CONFIG_DATA *UdpCfgData)
EFI_STATUS Dns6ConfigUdp(IN DNS_INSTANCE *Instance, IN UDP_IO *UdpIo)
EFI_STATUS EFIAPI GetDns6TokenEntry(IN NET_MAP *TokensMap, IN EFI_DNS6_COMPLETION_TOKEN *Token, OUT DNS6_TOKEN_ENTRY **TokenEntry)