@@ -55,10 +55,6 @@ export interface WalletMiddlewareOptions {
55
55
address : string ,
56
56
req : JsonRpcRequest ,
57
57
) => Promise < string > ;
58
- processEthSignMessage ?: (
59
- msgParams : MessageParams ,
60
- req : JsonRpcRequest ,
61
- ) => Promise < string > ;
62
58
processPersonalMessage ?: (
63
59
msgParams : MessageParams ,
64
60
req : JsonRpcRequest ,
@@ -92,7 +88,6 @@ export function createWalletMiddleware({
92
88
getAccounts,
93
89
processDecryptMessage,
94
90
processEncryptionPublicKey,
95
- processEthSignMessage,
96
91
processPersonalMessage,
97
92
processTransaction,
98
93
processSignTransaction,
@@ -113,7 +108,6 @@ WalletMiddlewareOptions): JsonRpcMiddleware<any, Block> {
113
108
eth_sendTransaction : createAsyncMiddleware ( sendTransaction ) ,
114
109
eth_signTransaction : createAsyncMiddleware ( signTransaction ) ,
115
110
// message signatures
116
- eth_sign : createAsyncMiddleware ( ethSign ) ,
117
111
eth_signTypedData : createAsyncMiddleware ( signTypedData ) ,
118
112
eth_signTypedData_v3 : createAsyncMiddleware ( signTypedDataV3 ) ,
119
113
eth_signTypedData_v4 : createAsyncMiddleware ( signTypedDataV4 ) ,
@@ -195,36 +189,6 @@ WalletMiddlewareOptions): JsonRpcMiddleware<any, Block> {
195
189
//
196
190
// message signatures
197
191
//
198
-
199
- async function ethSign (
200
- req : JsonRpcRequest ,
201
- res : PendingJsonRpcResponse < Json > ,
202
- ) : Promise < void > {
203
- if ( ! processEthSignMessage ) {
204
- throw rpcErrors . methodNotSupported ( ) ;
205
- }
206
- if (
207
- ! req ?. params ||
208
- ! Array . isArray ( req . params ) ||
209
- ! ( req . params . length >= 2 )
210
- ) {
211
- throw rpcErrors . invalidInput ( ) ;
212
- }
213
-
214
- const params = req . params as [ string , string , Record < string , string > ?] ;
215
- const address : string = await validateAndNormalizeKeyholder ( params [ 0 ] , req ) ;
216
- const message = params [ 1 ] ;
217
- const extraParams = params [ 2 ] || { } ;
218
- const msgParams : MessageParams = {
219
- ...extraParams ,
220
- from : address ,
221
- data : message ,
222
- signatureMethod : 'eth_sign' ,
223
- } ;
224
-
225
- res . result = await processEthSignMessage ( msgParams , req ) ;
226
- }
227
-
228
192
async function signTypedData (
229
193
req : JsonRpcRequest ,
230
194
res : PendingJsonRpcResponse < Json > ,
0 commit comments