File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6868 utils .KeyStoreDirFlag ,
6969 utils .ExternalSignerFlag ,
7070 utils .NoUSBFlag ,
71+ utils .USBFlag ,
7172 utils .SmartCardDaemonPathFlag ,
7273 utils .EthashCacheDirFlag ,
7374 utils .EthashCachesInMemoryFlag ,
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ var AppHelpFlagGroups = []flags.FlagGroup{
3737 utils .DataDirFlag ,
3838 utils .AncientFlag ,
3939 utils .KeyStoreDirFlag ,
40- utils .NoUSBFlag ,
40+ utils .USBFlag ,
4141 utils .SmartCardDaemonPathFlag ,
4242 utils .NetworkIdFlag ,
4343 utils .GoerliFlag ,
@@ -219,6 +219,7 @@ var AppHelpFlagGroups = []flags.FlagGroup{
219219 {
220220 Name : "ALIASED (deprecated)" ,
221221 Flags : append ([]cli.Flag {
222+ utils .NoUSBFlag ,
222223 utils .LegacyRPCEnabledFlag ,
223224 utils .LegacyRPCListenAddrFlag ,
224225 utils .LegacyRPCPortFlag ,
Original file line number Diff line number Diff line change @@ -119,7 +119,11 @@ var (
119119 }
120120 NoUSBFlag = cli.BoolFlag {
121121 Name : "nousb" ,
122- Usage : "Disables monitoring for and managing USB hardware wallets" ,
122+ Usage : "Disables monitoring for and managing USB hardware wallets (deprecated)" ,
123+ }
124+ USBFlag = cli.BoolFlag {
125+ Name : "usb" ,
126+ Usage : "Enable monitoring and management of USB hardware wallets" ,
123127 }
124128 SmartCardDaemonPathFlag = cli.StringFlag {
125129 Name : "pcscdpath" ,
@@ -1225,8 +1229,11 @@ func SetNodeConfig(ctx *cli.Context, cfg *node.Config) {
12251229 if ctx .GlobalIsSet (LightKDFFlag .Name ) {
12261230 cfg .UseLightweightKDF = ctx .GlobalBool (LightKDFFlag .Name )
12271231 }
1232+ if ctx .GlobalIsSet (USBFlag .Name ) {
1233+ cfg .NoUSB = ! ctx .GlobalBool (USBFlag .Name )
1234+ }
12281235 if ctx .GlobalIsSet (NoUSBFlag .Name ) {
1229- cfg . NoUSB = ctx . GlobalBool ( NoUSBFlag . Name )
1236+ log . Warn ( "Option nousb is deprecated and USB is deactivated by default. Use --usb to enable" )
12301237 }
12311238 if ctx .GlobalIsSet (InsecureUnlockAllowedFlag .Name ) {
12321239 cfg .InsecureUnlockAllowed = ctx .GlobalBool (InsecureUnlockAllowedFlag .Name )
You can’t perform that action at this time.
0 commit comments