mirror of
https://github.com/kuroppoi/entralinked.git
synced 2026-03-21 17:24:40 -05:00
Revert 90cb874520
Some checks are pending
Build / dist (push) Waiting to run
Some checks are pending
Build / dist (push) Waiting to run
This commit is contained in:
parent
d8bef2f184
commit
f3a5df2ff6
|
|
@ -31,13 +31,14 @@ public class DnsQueryHandler extends SimpleChannelInboundHandler<DatagramDnsQuer
|
|||
logger.debug("Received {}", question);
|
||||
DnsRecordType type = question.type();
|
||||
|
||||
// We only need type A (32 bit IPv4) for the DS
|
||||
if(type != DnsRecordType.A) {
|
||||
logger.warn("Potentially unsupported record type in DNS question: {}", type);
|
||||
// return;
|
||||
logger.warn("Unsupported record type in DNS question: {}", type);
|
||||
return;
|
||||
}
|
||||
|
||||
ByteBuf addressBuffer = Unpooled.wrappedBuffer(hostAddress.getAddress());
|
||||
DefaultDnsRawRecord answer = new DefaultDnsRawRecord(question.name(), type, 300, addressBuffer);
|
||||
DefaultDnsRawRecord answer = new DefaultDnsRawRecord(question.name(), DnsRecordType.A, 0, addressBuffer);
|
||||
DatagramDnsResponse response = new DatagramDnsResponse(query.recipient(), query.sender(), query.id());
|
||||
response.addRecord(DnsSection.ANSWER, answer);
|
||||
ctx.writeAndFlush(response);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user