1
0

Third-party plugins: expand warning message

Remove lightning is experimental warning
This commit is contained in:
ThomasV
2025-06-02 11:47:24 +02:00
parent a23f370a43
commit c8ea5b6173
2 changed files with 15 additions and 18 deletions

View File

@@ -20,15 +20,21 @@ To prevent fund losses, please save this backup on another device.
It may be imported in another Electrum wallet with the same seed."""
)
MSG_LIGHTNING_EXPERIMENTAL_WARNING = _(
"""Lightning support in Electrum is experimental. Do not put large amounts in lightning channels."""
)
MSG_LIGHTNING_SCB_WARNING = _(
MSG_LIGHTNING_WARNING = _(
"""Electrum uses static channel backups. If you lose your wallet file, you will need to request your channel to be force-closed by the remote peer in order to recover your funds. This assumes that the remote peer is reachable, and has not lost its own data."""
)
MSG_LIGHTNING_WARNING = MSG_LIGHTNING_EXPERIMENTAL_WARNING + "\n\n" + MSG_LIGHTNING_SCB_WARNING
MSG_THIRD_PARTY_PLUGIN_WARNING = ' '.join([
'<b>' + _('Warning: Thirt-party plugins have access to your wallet!') + '</b>',
'<br/><br/>',
_('Installing this plugin will grant third-party software access to your wallet. You must trust the plugin not to be malicious.'),
_('You should at minimum check who the author of the plugin is, and be careful of imposters.'),
'<br/><br/>',
_('Third-party plugins are not endorsed by Electrum.'),
_('Electrum will not be responsible in case of theft, loss of funds or privacy that might result from third-party plugins.'),
'<br/><br/>',
_('To install this plugin, please enter your plugin authorization password') + ':'
])
MSG_CONFLICTING_BACKUP_INSTANCE = _(
"""Another instance of this wallet (same seed) has an open channel with the same remote node. If you create this channel, you will not be able to use both wallets at the same time.

View File

@@ -8,6 +8,7 @@ from PyQt6.QtWidgets import QLabel, QVBoxLayout, QGridLayout, QPushButton, QWidg
from PyQt6.QtCore import QTimer
from electrum.i18n import _
from electrum.gui import messages
from electrum.logging import get_logger
from .util import (WindowModalDialog, Buttons, CloseButton, WWLabel, insert_spaces, MessageBoxMixin,
@@ -77,7 +78,7 @@ class PluginDialog(WindowModalDialog):
remove_button.setText(_('Remove'))
buttons.insert(0, remove_button)
if not is_authorized:
auth_button = QPushButton('Authorize')
auth_button = QPushButton('Install')
auth_button.clicked.connect(self.do_authorize)
buttons.insert(0, auth_button)
else:
@@ -178,17 +179,7 @@ class PluginsDialog(WindowModalDialog, MessageBoxMixin):
self.init_plugins_password()
return None
# ask for url and password, same window
pw = self.password_dialog(
msg=' '.join([
_('<b>Warning</b>: Third-party plugins are not endorsed by Electrum!'),
'<br/><br/>',
_('If you install a third-party plugin, you trust the software not to be malicious.'),
_('Electrum will not be responsible in case of theft, loss of funds or privacy that might result from third-party plugins.'),
_('You should at minimum check who the author of the plugin is, and be careful of imposters.'),
'<br/><br/>',
_('Please enter your plugin authorization password') + ':'
])
)
pw = self.password_dialog(msg=messages.MSG_THIRD_PARTY_PLUGIN_WARNING)
if not pw:
return None
privkey = self.plugins.derive_privkey(pw, salt)