1 public string ByteToString(byte[] inputBytes) 2 { 3 StringBuilder temp = new StringBuilder(2048); 4 foreach (byte tempByte in inputBytes) 5 { 6 temp.Append(tempByte > 15 ? 7 Convert.ToString(tempByte, 2) : '0' + Convert.ToString(tempByte, 2)); 8 } 9 return temp.ToString(); 10 }