Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error [protocol]: Malformed packet: length 313 was specified, but read 206 bytes #88

Open
pylebecq opened this issue Oct 28, 2021 · 2 comments

Comments

@pylebecq
Copy link

Hello. Here is a bug I encountered while using dog:

Version and Operating system:

$ dog --version
dog ● command-line DNS client
v0.1.0
https://dns.lookup.dog/

Operating system: macOS Big Sur 11.6

$ uname -a
Darwin Pierre-Yvess-MacBook-Pro.local 20.6.0 Darwin Kernel Version 20.6.0: Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64 x86_64

Command used:

$ dog _spf.mailgun.org TXT
Error [protocol]: Malformed packet: length 313 was specified, but read 206 bytes

Expected result (from dig):

$ dig _spf.mailgun.org TXT

; <<>> DiG 9.10.6 <<>> _spf.mailgun.org TXT
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 33204
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;_spf.mailgun.org.		IN	TXT

;; ANSWER SECTION:
_spf.mailgun.org.	732	IN	TXT	"v=spf1 ip4:209.61.151.0/24 ip4:166.78.68.0/22 ip4:198.61.254.0/23 ip4:192.237.158.0/23 ip4:23.253.182.0/23 ip4:104.130.96.0/28 ip4:146.20.113.0/24 ip4:146.20.191.0/24 ip4:159.135.224.0/20 ip4:69.72.32.0/20" " ip4:104.130.122.0/23 ip4:146.20.112.0/26 ip4:141.193.32.0/23 ip4:161.38.192.0/20 ip4:143.55.224.0/20 ~all"

;; Query time: 14 msec
;; SERVER: 1.1.1.1#53(1.1.1.1)
;; WHEN: Thu Oct 28 17:50:32 CEST 2021
;; MSG SIZE  rcvd: 370
@benwaffle
Copy link

Same with dog me.com TXT

@benwaffle
Copy link

benwaffle commented Nov 16, 2021

Actually, looks like this bug is fixed in master

❯ ./target/debug/dog me.com TXT
TXT me.com. 5m00s   "v=spf1 ip4:17.41.0.0/16 ip4:17.58.0.0/16 ip4:17.110.0.0/15 ip4:17.142.0.0/15 ip4:17.162.0.0/15 ip4:17.164.0.0/16 ip4:17.171.37.0/24 ip4:17.172.0.0/16 ip4:17.179.168.0/23 ip4:144.178.36.0/24 ip4:144.178.38.0/24", " ip4:112.19.199.64/29 ip4:112.19.242.64/29 ip4:222.73.195.64/29 ip4:157.255.1.64/29 ip4:106.39.212.64/29 ip4:123.126.78.64/29 ip4:183.240.219.64/29 ip4:39.156.163.64/29 ip4:17.57.155.0/24 ip4:17.57.156.0/24 ~all"
❯ ./target/debug/dog _spf.mailgun.org txt
TXT _spf.mailgun.org. 1h00m00s   "v=spf1 ip4:209.61.151.0/24 ip4:166.78.68.0/22 ip4:198.61.254.0/23 ip4:192.237.158.0/23 ip4:23.253.182.0/23 ip4:104.130.96.0/28 ip4:146.20.113.0/24 ip4:146.20.191.0/24 ip4:159.135.224.0/20 ip4:69.72.32.0/20", " ip4:104.130.122.0/23 ip4:146.20.112.0/26 ip4:161.38.192.0/20 ip4:143.55.224.0/20 ~all"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants