import struct

def main():
    try:
        with open("login_user_dump.bin", "rb") as f:
            data = f.read()
            print(f"Data Length: {len(data)}")
            print(f"First 100 bytes (Hex): {data[:100].hex()}")
            print(f"First 100 bytes (Str): {data[:100]}")
            
            # Try Base64 Decode
            import base64
            try:
                decoded = base64.b64decode(data)
                print(f"\nBase64 Decoded First 100 bytes (Hex): {decoded[:100].hex()}")
                print(f"Base64 Decoded First 100 bytes (Str): {decoded[:100]}")
                
                # Check for AMF Header
                if decoded.startswith(b'\x00\x03') or decoded.startswith(b'\x00\x00'):
                    print("\nLooks like AMF!")
                else:
                    print("\nDoes NOT look like standard AMF header (00 03 or 00 00).")
            except Exception as e:
                print(f"\nBase64 Decode Error: {e}")
                
    except Exception as e:
        print(f"Error reading file: {e}")

if __name__ == "__main__":
    main()