zigap-utils 0.0.497 → 0.0.499

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +0,0 @@
1
- import { AccountType } from './types';
2
-
3
- declare class AddressProvideService {
4
- private isAccountType;
5
- getAccount(): Promise<AccountType>;
6
- qrAddressProvide(roomId: string): Promise<AccountType>;
7
- }
8
- declare const _default: AddressProvideService;
9
- export default _default;
@@ -1,19 +0,0 @@
1
- import { ec as EC } from 'elliptic';
2
-
3
- declare class CryptoService {
4
- private ec;
5
- constructor();
6
- xphereSign(msg: string, prKey: string): string;
7
- xphereVerify(msg: string, pubKey: string, sig: string): boolean;
8
- generateKeys(): {
9
- privateKey: string;
10
- publicKey: string;
11
- };
12
- sign(msg: string, prKey: string): EC.Signature;
13
- verify(msg: string, sig: EC.Signature, pubKey: string): boolean;
14
- encrypt(text: string, key: string): string;
15
- decrypt(encryptedText: string, key: string): string;
16
- generateNonce(length: number): string;
17
- }
18
- declare const _default: CryptoService;
19
- export default _default;
@@ -1,11 +0,0 @@
1
- import { AccountCryptoType, ResponseLoginType } from './types';
2
-
3
- declare class LoginService {
4
- private isAccountCryptoType;
5
- getAccountCrypto(): Promise<AccountCryptoType>;
6
- reciveRequest(): Promise<boolean>;
7
- sendMessage(roomId: string, message: string): Promise<void>;
8
- qrLogin(roomId: string, message: string, nonce: string): Promise<ResponseLoginType>;
9
- }
10
- declare const _default: LoginService;
11
- export default _default;
@@ -1,7 +0,0 @@
1
- import { QrType } from './types';
2
-
3
- declare class QrService {
4
- generateQrCode(type: string, dapp: string, url: string, network: string[]): QrType;
5
- }
6
- declare const _default: QrService;
7
- export default _default;
@@ -1,9 +0,0 @@
1
- import { Socket } from 'socket.io-client';
2
-
3
- declare class SocketInstance {
4
- private static instance;
5
- socket: Socket;
6
- private constructor();
7
- static getInstance(): SocketInstance;
8
- }
9
- export default SocketInstance;
@@ -1,24 +0,0 @@
1
- import { ec as EC } from 'elliptic';
2
-
3
- export type SignatureType = EC.Signature;
4
- export interface QrType {
5
- qrCode: string;
6
- roomId: string;
7
- }
8
- export interface AccountCryptoType {
9
- signature: string;
10
- publicKey: string;
11
- address: string;
12
- network: string;
13
- etc: string;
14
- }
15
- export interface AccountType {
16
- address: string;
17
- network: string;
18
- }
19
- export interface ResponseLoginType {
20
- address: string;
21
- network: string;
22
- signature: string;
23
- publicKey: string;
24
- }