Results 1 to 40 of 62

Thread: [RESOLVED] Bits, Bytes and Boomerangs (without the boomerangs...)

Threaded View

  1. #21

    Thread Starter
    Pro Grammar chris128's Avatar
    Join Date
    Jun 2007
    Location
    England
    Posts
    7,604

    Re: Bits, Bytes and Boomerangs (without the boomerangs...)

    Quote Originally Posted by mickey_pt View Post
    If you want to put the RD at 1 and everything else at 0...

    Just put the first byte a 1 and the second a 0
    HeaderBytes(2) = 1 (0000 0001)
    HeaderBytes(3) = 0 (0000 0000)
    but that wont be in the correct place will it? This is what I dont get, you guys are saying that the order of the bits (high to low vs low to high) doesnt make a difference as thats just how us humans like to view the bits - but in that header table it shows that single bits affect specific settings (in this case the RD setting) so surely I have to get them in the exact right place?
    Lets use a different example bit, lets say I wanted to set the TC bit, how would I do that? Again its just 1 bit I want to set so are you saying I should just do the same and set HeaderBytes to 1? If so then how will the DNS server that receives these bytes know I meant the TC bit and not some other bit in that word?
    Last edited by chris128; Sep 18th, 2009 at 12:56 PM.
    My free .NET Windows API library (Version 2.2 Released 12/06/2011)

    Blog: cjwdev.wordpress.com
    Web: www.cjwdev.co.uk


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width