tested soa packer. It works, but doesn't utilize compression pointers to full capabilities
このコミットが含まれているのは:
コミット
cfae86e5f1
@ -27,7 +27,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) {
|
||||
}
|
||||
if(!record.ret){
|
||||
throw new Error("no serial number for SOA record");
|
||||
}
|
||||
}
|
||||
if(!record.ex){
|
||||
throw new Error("no serial number for SOA record");
|
||||
}
|
||||
@ -35,7 +35,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) {
|
||||
throw new Error("no serial number for SOA record");
|
||||
}
|
||||
|
||||
var soaLen = 20; // take into account sn, ref, ret, ex, and nx
|
||||
var soaLen = 20; // take into account sn, ref, ret, ex, and nx
|
||||
// (32-bits each. 4Bytes * 5 = 20)
|
||||
var rdLenIndex = total;
|
||||
total += 2; // Save space for RDLENGTH
|
||||
@ -72,7 +72,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) {
|
||||
dv.setUint32(total, parseInt(record.ref, 10), false);
|
||||
total+=4;
|
||||
dv.setUint32(total, parseInt(record.ret, 10), false);
|
||||
total+=4;
|
||||
total+=4;
|
||||
dv.setUint32(total, parseInt(record.ex, 10), false);
|
||||
total+=4;
|
||||
dv.setUint32(total, parseInt(record.nx, 10), false);
|
||||
|
読み込み中…
x
新しいイシューから参照
ユーザーをブロックする