tjfontaine / native-dns-packet

DNS parsing and writing in javascript
MIT License
58 stars 36 forks source link

Fix #26: rcode bitmask should be 5 bits #27

Closed coolaj86 closed 8 years ago

coolaj86 commented 8 years ago

Fix #26:

From 0xF (4 bits) to 0x1F (5 bits, <= 31)

At the very least it doesn't seem to break anything.

coolaj86 commented 8 years ago

Verified working. I ran actual DNS linters and they're not complaining about BADVERS anymore.

stephank commented 8 years ago

Weird though! None of the RFCs define those fields as part of the RCODE. Extended RCODEs are defined in RFC 2671, where the OPT RR TTL field is used as 8 additional RCODE bits.

Either way, this is missing parser code, and overlaps with the res3 property.

taoeffect commented 8 years ago

@coolaj86 Re ac9739c, please do not spam projects.

coolaj86 commented 8 years ago

My apologies!! I was working from a list of my projects and forks and adding to all of them.

I thought I added to my fork not this main repo.

coolaj86 commented 8 years ago

Oh, it looks like it updated the pull request. I'll resubmit with just the bug fix.

coolaj86 commented 8 years ago

Re-requested as #34