Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Replicating Net::DNS::Packet

by moritz (Cardinal)
on Jun 07, 2014 at 07:50 UTC ( [id://1089126]=note: print w/replies, xml ) Need Help??


in reply to Replicating Net::DNS::Packet

A classic: Yes, even you can use CPAN

Anyway, it's actually pretty simple. Since all arguments are literals and thus constants, you install Net::DNS::Packet on one machine once, dump $dns_packet->data(), and use the resulting string by copy&paste wherever you want to use it.

Update: Small nit:

$dnspacket->header->ra(0); #Recursion Desired $dnspacket->header->rd(1); #Recursion Available

The comments are the wrong way around, the should be switched.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1089126]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2025-03-28 08:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When you first encountered Perl, which feature amazed you the most?










    Results (71 votes). Check out past polls.

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.