mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-22 17:29:01 +00:00
LibDNS: Enable EXPLICIT_SYMBOL_EXPORT
This commit is contained in:
parent
8150fb4cbb
commit
1573ca35cc
Notes:
github-actions[bot]
2025-08-24 18:59:32 +00:00
Author: https://github.com/ayeteadoe
Commit: 1573ca35cc
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5769
Reviewed-by: https://github.com/ADKaster ✅
Reviewed-by: https://github.com/R-Goc
2 changed files with 7 additions and 6 deletions
|
@ -2,5 +2,5 @@ set(SOURCES
|
||||||
Message.cpp
|
Message.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
ladybird_lib(LibDNS dns)
|
ladybird_lib(LibDNS dns EXPLICIT_SYMBOL_EXPORT)
|
||||||
target_link_libraries(LibDNS PRIVATE LibCore PUBLIC LibCrypto)
|
target_link_libraries(LibDNS PRIVATE LibCore PUBLIC LibCrypto)
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
#include <AK/IPv6Address.h>
|
#include <AK/IPv6Address.h>
|
||||||
#include <AK/RedBlackTree.h>
|
#include <AK/RedBlackTree.h>
|
||||||
#include <AK/Time.h>
|
#include <AK/Time.h>
|
||||||
|
#include <LibDNS/Export.h>
|
||||||
|
|
||||||
namespace DNS {
|
namespace DNS {
|
||||||
namespace Messages {
|
namespace Messages {
|
||||||
|
@ -84,7 +85,7 @@ struct Header {
|
||||||
NetworkOrdered<u16> additional_count;
|
NetworkOrdered<u16> additional_count;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct DomainName {
|
struct DNS_API DomainName {
|
||||||
Vector<ByteString> labels;
|
Vector<ByteString> labels;
|
||||||
|
|
||||||
static DomainName from_string(StringView);
|
static DomainName from_string(StringView);
|
||||||
|
@ -201,8 +202,8 @@ enum class ResourceType : u16 {
|
||||||
TA = 32768, // DNSSEC Trust Authorities "[Sam_Weiler][Deploying DNSSEC Without a Signed Root. Technical Report 1999-19, Information Networking Institute, Carnegie Mellon University, April 2004.]"
|
TA = 32768, // DNSSEC Trust Authorities "[Sam_Weiler][Deploying DNSSEC Without a Signed Root. Technical Report 1999-19, Information Networking Institute, Carnegie Mellon University, April 2004.]"
|
||||||
DLV = 32769, // DNSSEC Lookaside Validation (OBSOLETE) [RFC8749][RFC4431]
|
DLV = 32769, // DNSSEC Lookaside Validation (OBSOLETE) [RFC8749][RFC4431]
|
||||||
};
|
};
|
||||||
StringView to_string(ResourceType);
|
DNS_API StringView to_string(ResourceType);
|
||||||
Optional<ResourceType> resource_type_from_string(StringView);
|
DNS_API Optional<ResourceType> resource_type_from_string(StringView);
|
||||||
|
|
||||||
// Listing from IANA https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#dns-parameters-2.
|
// Listing from IANA https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#dns-parameters-2.
|
||||||
enum class Class : u16 {
|
enum class Class : u16 {
|
||||||
|
@ -693,7 +694,7 @@ using Record = Variant<
|
||||||
// TODO: Add more records.
|
// TODO: Add more records.
|
||||||
ByteBuffer>; // Fallback for unknown records.
|
ByteBuffer>; // Fallback for unknown records.
|
||||||
|
|
||||||
struct ResourceRecord {
|
struct DNS_API ResourceRecord {
|
||||||
DomainName name;
|
DomainName name;
|
||||||
ResourceType type;
|
ResourceType type;
|
||||||
Class class_;
|
Class class_;
|
||||||
|
@ -716,7 +717,7 @@ struct ZoneAuthority {
|
||||||
u32 minimum_ttl;
|
u32 minimum_ttl;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct Message {
|
struct DNS_API Message {
|
||||||
Header header;
|
Header header;
|
||||||
Vector<Question> questions;
|
Vector<Question> questions;
|
||||||
Vector<ResourceRecord> answers;
|
Vector<ResourceRecord> answers;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue