how to get file extension from byte array in c#