diff options
| -rw-r--r-- | Dockerfile.android | 9 | ||||
| -rw-r--r-- | Dockerfile.linux | 20 | ||||
| -rw-r--r-- | Dockerfile.windows | 19 | ||||
| -rw-r--r-- | components/TxConfirmationDialog.qml | 5 | ||||
| -rw-r--r-- | pages/History.qml | 2 | ||||
| -rw-r--r-- | pages/merchant/Merchant.qml | 2 | ||||
| -rw-r--r-- | pages/settings/SettingsInfo.qml | 2 | ||||
| -rw-r--r-- | src/main/oshelper.cpp | 6 | ||||
| -rw-r--r-- | src/main/oshelper.h | 1 | ||||
| -rw-r--r-- | src/p2pool/P2PoolManager.cpp | 24 | ||||
| -rw-r--r-- | wizard/WizardWalletInput.qml | 4 |
11 files changed, 44 insertions, 50 deletions
diff --git a/Dockerfile.android b/Dockerfile.android index 7e3189cc..e3ac4bf1 100644 --- a/Dockerfile.android +++ b/Dockerfile.android @@ -56,8 +56,9 @@ RUN wget -q https://github.com/madler/zlib/releases/download/v${ZLIB_VERSION}/zl && make -j${THREADS} install \ && rm -rf $(pwd) -RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 \ +RUN git clone https://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 \ && cd qt5 \ + && git reset --hard dc2ac680fa9d0ef7b0d9520859593d13951bedea \ && perl init-repository --module-subset=default,-qtwebengine \ && PATH=${HOST_PATH} ./configure -v -developer-build -release \ -xplatform android-clang \ @@ -90,7 +91,7 @@ RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 \ ARG ICONV_VERSION=1.16 ARG ICONV_HASH=e6a1b1b589654277ee790cce3734f07876ac4ccfaecbee8afa0b649cf529cc04 -RUN wget -q http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${ICONV_VERSION}.tar.gz \ +RUN wget -q https://ftp.gnu.org/pub/gnu/libiconv/libiconv-${ICONV_VERSION}.tar.gz \ && echo "${ICONV_HASH} libiconv-${ICONV_VERSION}.tar.gz" | sha256sum -c \ && tar -xzf libiconv-${ICONV_VERSION}.tar.gz \ && rm -f libiconv-${ICONV_VERSION}.tar.gz \ @@ -179,7 +180,7 @@ RUN set -ex \ && make -j${THREADS} install \ && rm -rf $(pwd) -RUN git clone -b libgpg-error-1.41 --depth 1 git://git.gnupg.org/libgpg-error.git \ +RUN git clone -b libgpg-error-1.41 --depth 1 https://github.com/gpg/libgpg-error \ && cd libgpg-error \ && git reset --hard 98032624ae89a67ee6fe3b1db5d95032e681d163 \ && ./autogen.sh \ @@ -188,7 +189,7 @@ RUN git clone -b libgpg-error-1.41 --depth 1 git://git.gnupg.org/libgpg-error.gi && make -j${THREADS} install \ && rm -rf $(pwd) -RUN git clone -b libgcrypt-1.10.1 --depth 1 git://git.gnupg.org/libgcrypt.git \ +RUN git clone -b libgcrypt-1.10.1 --depth 1 https://github.com/gpg/libgcrypt \ && cd libgcrypt \ && git reset --hard ae0e567820c37f9640440b3cff77d7c185aa6742 \ && ./autogen.sh \ diff --git a/Dockerfile.linux b/Dockerfile.linux index dc5795cf..24f6fd6c 100644 --- a/Dockerfile.linux +++ b/Dockerfile.linux @@ -188,20 +188,10 @@ RUN wget https://www.nlnetlabs.nl/downloads/unbound/unbound-1.16.2.tar.gz && \ RUN rm /usr/lib/x86_64-linux-gnu/libX11.a && \ rm /usr/lib/x86_64-linux-gnu/libXext.a && \ rm /usr/lib/x86_64-linux-gnu/libX11-xcb.a && \ - git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \ + git clone https://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \ cd qt5 && \ - git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtdeclarative.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtgraphicaleffects.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtquickcontrols.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtquickcontrols2.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtx11extras.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtxmlpatterns.git -b ${QT_VERSION} --depth 1 && \ + git reset --hard dc2ac680fa9d0ef7b0d9520859593d13951bedea && \ + git submodule update --init --depth 1 qtbase qtdeclarative qtgraphicaleffects qtimageformats qtmultimedia qtquickcontrols qtquickcontrols2 qtsvg qttools qttranslations qtx11extras qtxmlpatterns && \ sed -ri s/\(Libs:.*\)/\\1\ -lexpat/ /usr/local/lib/pkgconfig/fontconfig.pc && \ sed -ri s/\(Libs:.*\)/\\1\ -lz/ /usr/local/lib/pkgconfig/freetype2.pc && \ sed -ri s/\(Libs:.*\)/\\1\ -lXau/ /usr/local/lib/pkgconfig/xcb.pc && \ @@ -251,7 +241,7 @@ RUN git clone -b v4.3.4 --depth 1 https://github.com/zeromq/libzmq && \ make -j$THREADS install && \ rm -rf $(pwd) -RUN git clone -b libgpg-error-1.45 --depth 1 git://git.gnupg.org/libgpg-error.git && \ +RUN git clone -b libgpg-error-1.45 --depth 1 https://github.com/gpg/libgpg-error && \ cd libgpg-error && \ git reset --hard dbac537e5e865fb6f3aa8596d213aa8c47a9dea1 && \ ./autogen.sh && \ @@ -260,7 +250,7 @@ RUN git clone -b libgpg-error-1.45 --depth 1 git://git.gnupg.org/libgpg-error.gi make -j$THREADS install && \ rm -rf $(pwd) -RUN git clone -b libgcrypt-1.10.1 --depth 1 git://git.gnupg.org/libgcrypt.git && \ +RUN git clone -b libgcrypt-1.10.1 --depth 1 https://github.com/gpg/libgcrypt && \ cd libgcrypt && \ git reset --hard ae0e567820c37f9640440b3cff77d7c185aa6742 && \ ./autogen.sh && \ diff --git a/Dockerfile.windows b/Dockerfile.windows index 07542705..8bc4e2cd 100644 --- a/Dockerfile.windows +++ b/Dockerfile.windows @@ -21,19 +21,10 @@ RUN git clone -b v0.18.5.0 --depth 1 https://github.com/monero-project/monero && RUN make -j$THREADS -C /depends HOST=x86_64-w64-mingw32 NO_QT=1 -RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \ +RUN git clone https://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \ cd qt5 && \ - git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtdeclarative.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtgraphicaleffects.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtquickcontrols.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtquickcontrols2.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1 && \ - git clone git://code.qt.io/qt/qtxmlpatterns.git -b ${QT_VERSION} --depth 1 && \ + git reset --hard dc2ac680fa9d0ef7b0d9520859593d13951bedea && \ + git submodule update --init --depth 1 qtbase qtdeclarative qtgraphicaleffects qtimageformats qtmultimedia qtquickcontrols qtquickcontrols2 qtsvg qttools qttranslations qtxmlpatterns && \ ./configure --prefix=/depends/x86_64-w64-mingw32 -xplatform win32-g++ \ -device-option CROSS_COMPILE=/usr/bin/x86_64-w64-mingw32- \ -I $(pwd)/qtbase/src/3rdparty/angle/include \ @@ -58,7 +49,7 @@ RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \ cd ../../../.. && \ rm -rf $(pwd) -RUN git clone -b libgpg-error-1.38 --depth 1 git://git.gnupg.org/libgpg-error.git && \ +RUN git clone -b libgpg-error-1.38 --depth 1 https://github.com/gpg/libgpg-error && \ cd libgpg-error && \ git reset --hard 71d278824c5fe61865f7927a2ed1aa3115f9e439 && \ ./autogen.sh && \ @@ -69,7 +60,7 @@ RUN git clone -b libgpg-error-1.38 --depth 1 git://git.gnupg.org/libgpg-error.gi cd .. && \ rm -rf libgpg-error -RUN git clone -b libgcrypt-1.8.5 --depth 1 git://git.gnupg.org/libgcrypt.git && \ +RUN git clone -b libgcrypt-1.8.5 --depth 1 https://github.com/gpg/libgcrypt && \ cd libgcrypt && \ git reset --hard 56606331bc2a80536db9fc11ad53695126007298 && \ ./autogen.sh && \ diff --git a/components/TxConfirmationDialog.qml b/components/TxConfirmationDialog.qml index 1700aa0a..51da022f 100644 --- a/components/TxConfirmationDialog.qml +++ b/components/TxConfirmationDialog.qml @@ -242,6 +242,7 @@ Rectangle { Layout.fillWidth: true font.pixelSize: 15 color: MoneroComponents.Style.defaultFontColor + textFormat: Text.RichText text: { if (currentWallet) { var walletTitle = function() { @@ -257,9 +258,9 @@ Rectangle { if (appWindow.currentWallet.numSubaddressAccounts() > 1) { var currentSubaddressAccount = currentWallet.currentSubaddressAccount; var currentAccountLabel = currentWallet.getSubaddressLabel(currentWallet.currentSubaddressAccount, 0); - return walletTitle() + " (" + walletName + ")" + "<br>" + qsTr("Account #") + currentSubaddressAccount + (currentAccountLabel !== "" ? " (" + currentAccountLabel + ")" : "") + translationManager.emptyString; + return walletTitle() + " (" + Utils.htmlEscape(walletName) + ")" + "<br>" + qsTr("Account #") + currentSubaddressAccount + (currentAccountLabel !== "" ? " (" + Utils.htmlEscape(currentAccountLabel) + ")" : "") + translationManager.emptyString; } else { - return walletTitle() + " (" + walletName + ")" + translationManager.emptyString; + return walletTitle() + " (" + Utils.htmlEscape(walletName) + ")" + translationManager.emptyString; } } else { return ""; diff --git a/pages/History.qml b/pages/History.qml index d9132e3b..6871405d 100644 --- a/pages/History.qml +++ b/pages/History.qml @@ -1746,7 +1746,7 @@ Rectangle { + (paymentId ? trStart + qsTr("Payment ID:") + trMiddle + paymentId + trEnd : "") + (integratedAddress ? trStart + qsTr("Integrated address") + ":" + trMiddle + integratedAddress + trEnd : "") + (tx_key ? trStart + qsTr("Tx key:") + trMiddle + tx_key + trEnd : "") - + (tx_note ? trStart + qsTr("Tx note:") + trMiddle + tx_note + trEnd : "") + + (tx_note ? trStart + qsTr("Tx note:") + trMiddle + Utils.htmlEscape(tx_note) + trEnd : "") + (destinations ? trStart + qsTr("Destinations:") + trMiddle + destinations + trEnd : "") + (rings ? trStart + qsTr("Rings:") + trMiddle + rings + trEnd : "") + "</table>" diff --git a/pages/merchant/Merchant.qml b/pages/merchant/Merchant.qml index 560484b1..86d47560 100644 --- a/pages/merchant/Merchant.qml +++ b/pages/merchant/Merchant.qml @@ -295,7 +295,7 @@ Item { color: "white" text: "<style type='text/css'>a {text-decoration: none; color: #FF6C3C; font-size: 12px;}</style>%1: %2 <a href='#'>(%3)</a>" .arg(qsTr("Currently selected address")) - .arg(addressLabel) + .arg(Utils.htmlEscape(addressLabel)) .arg(qsTr("Change")) + translationManager.emptyString textFormat: Text.RichText themeTransition: false diff --git a/pages/settings/SettingsInfo.qml b/pages/settings/SettingsInfo.qml index ad152d63..e126383a 100644 --- a/pages/settings/SettingsInfo.qml +++ b/pages/settings/SettingsInfo.qml @@ -142,7 +142,7 @@ Rectangle { <style type='text/css'>\ a {cursor:pointer;text-decoration: none; color: #FF6C3C}\ </style>\ - <a href='#'>%1</a>".arg(walletPath) + <a href='#'>%1</a>".arg(Utils.htmlEscape(walletPath)) textFormat: Text.RichText onLinkActivated: oshelper.openContainingFolder(walletPath) diff --git a/src/main/oshelper.cpp b/src/main/oshelper.cpp index 2ca0e400..cb9aca7a 100644 --- a/src/main/oshelper.cpp +++ b/src/main/oshelper.cpp @@ -248,6 +248,12 @@ QString OSHelper::temporaryPath() const return QDir::tempPath(); } +bool OSHelper::isWritableDirectory(const QString &path) const +{ + const QFileInfo info(path); + return info.exists() && info.isDir() && info.isWritable(); +} + QString OSHelper::randomPassword(int numBytes) const { numBytes = qBound(16, numBytes, 128); diff --git a/src/main/oshelper.h b/src/main/oshelper.h index 1c3aeb72..b6e98d32 100644 --- a/src/main/oshelper.h +++ b/src/main/oshelper.h @@ -51,6 +51,7 @@ public: Q_INVOKABLE QString openSaveFileDialog(const QString &title, const QString &folder, const QString &filename) const; Q_INVOKABLE QString temporaryFilename() const; Q_INVOKABLE QString temporaryPath() const; + Q_INVOKABLE bool isWritableDirectory(const QString &path) const; Q_INVOKABLE QString randomPassword(int numBytes = 32) const; Q_INVOKABLE bool removeTemporaryWallet(const QString &walletName) const; Q_INVOKABLE bool isCapsLock() const; diff --git a/src/p2pool/P2PoolManager.cpp b/src/p2pool/P2PoolManager.cpp index c1e580e4..64414f0c 100644 --- a/src/p2pool/P2PoolManager.cpp +++ b/src/p2pool/P2PoolManager.cpp @@ -55,21 +55,21 @@ void P2PoolManager::download() { QString fileName; QString validHash; #ifdef Q_OS_WIN - url = "https://github.com/SChernykh/p2pool/releases/download/v4.16/p2pool-v4.16-windows-x64.zip"; - fileName = m_p2poolPath + "/p2pool-v4.16-windows-x64.zip"; - validHash = "8f619bf215e986f8b96526a1a279b83c84b569a0916c1d19713bfb616e78160a"; + url = "https://github.com/SChernykh/p2pool/releases/download/v4.17.1/p2pool-v4.17.1-windows-x64.zip"; + fileName = m_p2poolPath + "/p2pool-v4.17.1-windows-x64.zip"; + validHash = "984822dd8a4645ea68763888d2127085bbb53ed42b35e1f899883b3a35a40a76"; #elif defined(Q_OS_LINUX) - url = "https://github.com/SChernykh/p2pool/releases/download/v4.16/p2pool-v4.16-linux-x64.tar.gz"; - fileName = m_p2poolPath + "/p2pool-v4.16-linux-x64.tar.gz"; - validHash = "1b03b2e4d4adfe488b2867eb85b57366fbaf8594a7f84cdbf13a3c8519159280"; + url = "https://github.com/SChernykh/p2pool/releases/download/v4.17.1/p2pool-v4.17.1-linux-x64.tar.gz"; + fileName = m_p2poolPath + "/p2pool-v4.17.1-linux-x64.tar.gz"; + validHash = "66b67fd8c7f00d33e76b3fa8373e67a5880a530ff1812aaf39aa85298d328f6c"; #elif defined(Q_OS_MACOS_AARCH64) - url = "https://github.com/SChernykh/p2pool/releases/download/v4.16/p2pool-v4.16-macos-aarch64.tar.gz"; - fileName = m_p2poolPath + "/p2pool-v4.16-macos-aarch64.tar.gz"; - validHash = "8e1d8c10850015c50cc4955dc3b9681007f329d51325a3a55bde700298bcfaeb"; + url = "https://github.com/SChernykh/p2pool/releases/download/v4.17.1/p2pool-v4.17.1-macos-aarch64.tar.gz"; + fileName = m_p2poolPath + "/p2pool-v4.17.1-macos-aarch64.tar.gz"; + validHash = "8b8454fb4d8330b4a039d4657be69c8543a22938a8957c083512be41e27016b1"; #elif defined(Q_OS_MACOS) - url = "https://github.com/SChernykh/p2pool/releases/download/v4.16/p2pool-v4.16-macos-x64.tar.gz"; - fileName = m_p2poolPath + "/p2pool-v4.16-macos-x64.tar.gz"; - validHash = "573b6aa9b953fb5594f7eb21b1321a8d719e181b6814f931ce54b603dc6f0663"; + url = "https://github.com/SChernykh/p2pool/releases/download/v4.17.1/p2pool-v4.17.1-macos-x64.tar.gz"; + fileName = m_p2poolPath + "/p2pool-v4.17.1-macos-x64.tar.gz"; + validHash = "64657dd2ae954d41880aef98193124d1d08dfa2e991f755a9d089a35f96def13"; #endif QFile file(fileName); epee::net_utils::http::http_simple_client http_client; diff --git a/wizard/WizardWalletInput.qml b/wizard/WizardWalletInput.qml index da7a4aaa..2054fe52 100644 --- a/wizard/WizardWalletInput.qml +++ b/wizard/WizardWalletInput.qml @@ -154,6 +154,10 @@ GridLayout { errorMessageWalletLocation.text = qsTr("Wallet location is empty") + translationManager.emptyString; return false; } + if (!oshelper.isWritableDirectory(walletLocation.text)) { + errorMessageWalletLocation.text = qsTr("Wallet location does not exist or is not writable") + translationManager.emptyString; + return false; + } errorMessageWalletLocation.text = ""; return true; } |
