public static ulong DecodeMultiByteLong(IBerInput input) { byte currentByte; ulong value = 0; do { currentByte = input.ReadByte(); value = (value << 7) | (byte)(currentByte & ~0x80); } while((currentByte & 0x80) != 0); return value; }