title: C# int to byte[]
body: <p>I need to convert an <code>int</code> to a <code>byte[]</code> one way of doing it is to use <code>BitConverter.GetBytes()</code>. But im unsure if that matches the following specification: </p>
  
  <blockquote>
    <p>An XDR signed integer is a 32-bit datum that encodes an integer in
       the range [-2147483648,2147483647].  The integer is represented in
       two's complement notation.  The most and least significant bytes are
       0 and 3, respectively.  Integers are declared as follows:</p>
  </blockquote>
  
  <p>Source: <code>RFC1014 3.2</code></p>
  
  <p>How could i do a int to byte transformation that would satisfy the above specification?</p>