successfully generates the wireguard config file

This commit is contained in:
2025-12-05 05:36:14 +08:00
parent cf3d999a2e
commit c4a50e8b3b
12 changed files with 820 additions and 64 deletions
-2
View File
@@ -16,8 +16,6 @@ export const signMessage = async (message: string,provider: EIP1193Provider,user
// For historical reasons, you must submit the message to sign in hex-encoded UTF-8.
// This uses a Node.js-style buffer shim in the browser.
// const bytes = new TextEncoder().encode(String(publicKey));
// const msg = '0x' + Array.from(bytes).map(b => b.toString(16).padStart(2, '0')).join('');
const msg = `0x${Buffer.from(message, "utf8").toString("hex")}`
const sig = await provider.request({
method: "personal_sign",
@@ -1,4 +1,3 @@
// ...existing code...
import React, { useState } from "react";
import { useSyncProviders } from "./useSyncProviders";
import useAuth from "~/hooks/useAuth";
@@ -122,5 +121,4 @@ export const DiscoverWalletProviders: React.FC = () => {
);
};
export default DiscoverWalletProviders;
// ...existing code...
export default DiscoverWalletProviders;