Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 17 additions & 14 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
name: Build on macOS
runs-on: macos-latest
env:
MACOSX_DEPLOYMENT_TARGET: 13.3
MACOSX_DEPLOYMENT_TARGET: 14.0
LIBS_PATH: ${{ github.workspace }}/cache
steps:
- &Checkout
Expand Down Expand Up @@ -41,12 +41,12 @@ jobs:
key: vcpkg-macOS-${{ hashFiles('prepare_osx_build_environment.sh') }}
- name: Build libraries
run: |
mkdir -p ${LIBS_PATH}/Qt-6.10.2-OpenSSL
mkdir -p ${LIBS_PATH}/Qt-6.11.1-OpenSSL
./prepare_osx_build_environment.sh -p ${LIBS_PATH}
- name: Install Qt
uses: jurplel/install-qt-action@v4
with:
version: 6.10.2
version: 6.10.3
arch: clang_64
cache: true
- name: Build
Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:
path: build/qdigidoc4*.rpm
windows:
name: Build on Windows
runs-on: ${{ matrix.platform == 'arm64' && 'windows-11-arm' || 'windows-2025' }}
runs-on: windows-2022
strategy:
matrix:
vcver: [143]
Expand All @@ -167,7 +167,8 @@ jobs:
- name: Install artifact
run: |
Rename-Item "libdigidocpp*.msi" libdigidocpp.msi
msiexec /qn /i libdigidocpp.msi
$r = Start-Process msiexec -ArgumentList '/a', 'libdigidocpp.msi', '/qn', "TARGETDIR=$env:GITHUB_WORKSPACE\libs", '/l*v', 'install.log' -Wait -PassThru
if ($r.ExitCode -ne 0) { Get-Content install.log; exit $r.ExitCode }
- name: Cache vcpkg
uses: actions/cache@v5
with:
Expand All @@ -176,24 +177,26 @@ jobs:
- name: Install Qt
uses: jurplel/install-qt-action@v4
with:
version: 6.10.2
arch: ${{ matrix.platform == 'arm64' && 'win64_msvc2022_arm64' || 'win64_msvc2022_64' }}
version: 6.11.1
arch: ${{ matrix.platform == 'arm64' && 'win64_msvc2022_arm64_cross_compiled' || 'win64_msvc2022_64' }}
cache: true
- name: Setup dev env
uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{ matrix.platform }}
aqtsource: git+https://github.com/miurahr/aqtinstall.git
- name: Install WiX
run: |
dotnet tool install -g wix --version 6.0.2
wix extension -g add WixToolset.UI.wixext/6.0.2
- name: Build
shell: cmd
env:
VCPKG_BINARY_SOURCES: clear;files,${{ github.workspace }}/vcpkg_cache,readwrite
run: |
cmake "-GNinja" -B build -S . -DCMAKE_BUILD_TYPE=RelWithDebInfo `
-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake `
-DVCPKG_MANIFEST_DIR=${{ github.workspace }}/client/libcdoc
for /f "usebackq tokens=*" %%i in (`"%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe" -latest -find VC\Auxiliary\Build\vcvarsall.bat`) do call "%%i" ${{ matrix.platform == 'arm64' && 'amd64_arm64' || 'amd64' }}
set QT_HOST_PATH=%QT_HOST_PATH:\=/%
cmake -GNinja -B build -S . -DCMAKE_BUILD_TYPE=RelWithDebInfo ^
-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake ^
-DVCPKG_MANIFEST_DIR=${{ github.workspace }}/client/libcdoc ^
-Dlibdigidocpp_ROOT=${{ github.workspace }}/libs/PFiles64 ^
${{ matrix.platform == 'arm64' && '-DQT_HOST_PATH=%QT_HOST_PATH%' || '' }}
cmake --build build --target msi
cmake --build build --target msishellext
cmake --build build --target appx
Expand Down
5 changes: 4 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.22)
if(NOT EXISTS ${CMAKE_SOURCE_DIR}/common/CMakeLists.txt)
message(FATAL_ERROR "common submodule directory empty, did you 'git clone --recursive'?")
endif()
project(qdigidoc4 VERSION 4.10.0
project(qdigidoc4 VERSION 4.11.0
DESCRIPTION "DigiDoc4 application for digital signing and encryption"
HOMEPAGE_URL https://github.com/open-eid/DigiDoc4-Client
)
Expand Down Expand Up @@ -33,6 +33,9 @@ set(CMAKE_CXX_STANDARD 23)
set(CMAKE_CXX_STANDARD_REQUIRED YES)
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION YES)
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION_DEBUG NO)
set(CMAKE_DISABLE_FIND_PACKAGE_Boost ON)
set(CMAKE_DISABLE_FIND_PACKAGE_Doxygen ON)
set(CMAKE_DISABLE_FIND_PACKAGE_SWIG ON)
set(CPACK_PACKAGE_VERSION ${VERSION})
set(CPACK_GENERATOR RPM)
set(CPACK_PACKAGE_CONTACT "RIA <info@ria.ee>")
Expand Down
25 changes: 0 additions & 25 deletions COPYING
Original file line number Diff line number Diff line change
Expand Up @@ -264,28 +264,3 @@ client/fonts
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

_______________________________________________________________________________
schema

MIT License

Copyright (c) 2023 Open Electronic Identity

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
3. Configure

cmake -B build -S . \
-DCMAKE_PREFIX_PATH=~/cmake_builds/Qt-6.10.2-OpenSSL
-DCMAKE_PREFIX_PATH=~/cmake_builds/Qt-6.11.1-OpenSSL \
-DOPENSSL_ROOT_DIR=~/cmake_build/OpenSSL \
-DLDAP_ROOT=~/cmake_build/OpenLDAP \
-DCMAKE_OSX_ARCHITECTURES="x86_64;arm64"
Expand Down Expand Up @@ -95,7 +95,7 @@
3. Configure

cmake -G"NMAKE Makefiles" -B build -S . `
-DCMAKE_PREFIX_PATH=C:\Qt\6.10.2\msvc2022_x64 `
-DCMAKE_PREFIX_PATH=C:\Qt\6.11.1\msvc2022_64 `
-DLibDigiDocpp_ROOT="C:\Program Files (x86)\libdigidocpp" `
-DVCPKG_MANIFEST_DIR=client/libcdoc

Expand Down
6 changes: 6 additions & 0 deletions RELEASE-NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
DigiDoc4 version [4.10.0](https://github.com/open-eid/DigiDoc4-Client/releases/tag/v4.10.0) release notes
--------------------------------------
- Code, Text and translation improvements and updates

[Full Changelog](https://github.com/open-eid/DigiDoc4-Client/compare/v4.9.0...v4.10.0)

DigiDoc4 version [4.9.0](https://github.com/open-eid/DigiDoc4-Client/releases/tag/v4.9.0) release notes
--------------------------------------
- Code, Text and translation improvements and updates
Expand Down
10 changes: 8 additions & 2 deletions client/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ add_executable(${PROJECT_NAME} WIN32 MACOSX_BUNDLE
DateTime.cpp
DateTime.h
Diagnostics.cpp
$<IF:$<PLATFORM_ID:Windows>,Diagnostics_win.cpp,Diagnostics_unix.cpp>
Diagnostics_win.cpp
Diagnostics_unix.cpp
Diagnostics.h
DiagnosticsTask.cpp
DiagnosticsTask.h
Expand Down Expand Up @@ -78,6 +79,11 @@ add_executable(${PROJECT_NAME} WIN32 MACOSX_BUNDLE
TokenData.h
Utils.h
)
if(WIN32)
set_source_files_properties(Diagnostics_unix.cpp PROPERTIES HEADER_FILE_ONLY TRUE)
else()
set_source_files_properties(Diagnostics_win.cpp PROPERTIES HEADER_FILE_ONLY TRUE)
endif()
qt_add_translations(${PROJECT_NAME} TS_FILES
translations/en.ts
translations/et.ts
Expand Down Expand Up @@ -250,7 +256,7 @@ elseif(WIN32)
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:EsteidShellExtensionV2> appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libcrypto-3${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libssl-3${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/zlib$<$<CONFIG:Debug>:d>1.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/z$<$<CONFIG:Debug>:d>.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libxml2.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libxmlsec1.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libxmlsec1-openssl.dll appx
Expand Down
20 changes: 5 additions & 15 deletions client/CryptoDoc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Q_LOGGING_CATEGORY(CRYPTO, "CRYPTO")

CKey::CKey(QSslCertificate _rcpt_cert) : lock(libcdoc::Lock::PUBLIC_KEY), rcpt_cert(_rcpt_cert) {
SslCertificate ssl(rcpt_cert);
lock.pk_type = (rcpt_cert.publicKey().algorithm() == QSsl::Ec) ? libcdoc::PKType::ECC : libcdoc::PKType::RSA;
lock.pk_type = (rcpt_cert.publicKey().algorithm() == QSsl::Ec) ? libcdoc::Algorithm::ECC : libcdoc::Algorithm::RSA;
QByteArray der = ssl.publicKeyDer();
lock.setBytes(libcdoc::Lock::RCPT_KEY, std::vector<uint8_t>(der.cbegin(), der.cend()));
der = rcpt_cert.toDer();
Expand Down Expand Up @@ -467,21 +467,13 @@ bool CryptoDoc::encrypt(const QString &filename, const QString& label, const QBy
for (const auto &key : d->keys) {
if (!key.rcpt_cert.isNull()) {
QByteArray ba = key.rcpt_cert.toDer();
enc_keys.push_back(keyserver_id.empty() ?
libcdoc::Recipient::makeCertificate({}, {ba.cbegin(), ba.cend()}) :
libcdoc::Recipient::makeServer({}, {ba.cbegin(), ba.cend()}, keyserver_id));
enc_keys.push_back(libcdoc::Recipient::makeCertificate({}, {ba.cbegin(), ba.cend()}, keyserver_id));
} else {
switch (key.lock.type) {
case libcdoc::Lock::CDOC1:
enc_keys.push_back(libcdoc::Recipient::makePublicKey(key.lock));
break;
case libcdoc::Lock::PUBLIC_KEY:
case libcdoc::Lock::SERVER:
if (keyserver_id.empty()) {
enc_keys.push_back(libcdoc::Recipient::makePublicKey(key.lock));
} else {
enc_keys.push_back(libcdoc::Recipient::makeServer(key.lock, keyserver_id));
}
enc_keys.push_back(libcdoc::Recipient::makePublicKey(key.lock, keyserver_id));
break;
default:
break;
Expand Down Expand Up @@ -512,10 +504,8 @@ bool CryptoDoc::encrypt(const QString &filename, const QString& label, const QBy
->withText(tr("Please check your internet connection and network settings."))
->withDetails(writer_last_error)
->open();
} else {
this->clear(d->fileName);
this->open(d->fileName);
}
} else
open(d->fileName);
return d->isEncrypted();
}

Expand Down
2 changes: 1 addition & 1 deletion client/Diagnostics_win.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ void Diagnostics::run()
static const QStringList dlls{
"digidocpp", "qdigidoc4.exe", "EsteidShellExtension", "id-updater.exe", "web-eid.exe",
"EstIDMinidriver", "EstIDMinidriver64", "EestiMinidriver", "EestiMinidriver64", "estgsv4md", "estgsv4md64",
"zlib1", "libxml2", "libxmlsec1", "libxmlsec1-openssl",
"zlib1", "z", "libxml2", "libxmlsec1", "libxmlsec1-openssl",
"msvcp140", "msvcp140_1", "msvcp140_2", "vcruntime140", "vcruntime140_1"};
for(const QString &lib: dlls)
{
Expand Down
2 changes: 1 addition & 1 deletion client/dialogs/FileDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ QString FileDialog::createNewFileName(const QString &file, bool signature, QWidg
#ifndef Q_OS_MACOS
// macOS App Sandbox restricts the rights of the application to write to the filesystem outside of
// app sandbox; user must explicitly give permission to write data to the specific folders.
if(!QFile::exists(fileName))
if(!QFile::exists(fileName) && fileIsWritable(fileName))
return fileName;
#endif
fileName = FileDialog::getSaveFileName(parent, tr("Create %1").arg(type), fileName,
Expand Down
16 changes: 6 additions & 10 deletions client/translations/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -541,10 +541,6 @@
<source>Continue signing</source>
<translation>Continue signing</translation>
</message>
<message>
<source>Cannot alter container %1. Save different location?</source>
<translation>Cannot alter container %1. Save to different location?</translation>
</message>
<message>
<source>Encrypting</source>
<translation>Encrypting</translation>
Expand Down Expand Up @@ -697,27 +693,27 @@
</message>
<message>
<source>Unknown - error %1</source>
<translation type="vanished">Unknown - error %1</translation>
<translation>Unknown - error %1</translation>
</message>
<message>
<source>User</source>
<translation type="vanished">User</translation>
<translation>User</translation>
</message>
<message>
<source>Administrator</source>
<translation type="vanished">Administrator</translation>
<translation>Administrator</translation>
</message>
<message>
<source>User rights: </source>
<translation type="vanished">User rights: </translation>
<translation>User rights: </translation>
</message>
<message>
<source>Not found</source>
<translation type="vanished">Not found</translation>
<translation>Not found</translation>
</message>
<message>
<source>Certificate Propagation service status: </source>
<translation type="vanished">Certificate Propagation service status: </translation>
<translation>Certificate Propagation service status: </translation>
</message>
<message>
<source>is set manually</source>
Expand Down
16 changes: 6 additions & 10 deletions client/translations/et.ts
Original file line number Diff line number Diff line change
Expand Up @@ -541,10 +541,6 @@
<source>Continue signing</source>
<translation>Jätka allkirjastamisega</translation>
</message>
<message>
<source>Cannot alter container %1. Save different location?</source>
<translation>Ümbriku %1 salvestamine ebaõnnestus. Salvestada teise asukohta?</translation>
</message>
<message>
<source>Encrypting</source>
<translation>Krüpteerin</translation>
Expand Down Expand Up @@ -697,27 +693,27 @@
</message>
<message>
<source>Unknown - error %1</source>
<translation type="vanished">Teadmata - viga %1</translation>
<translation>Teadmata - viga %1</translation>
</message>
<message>
<source>User</source>
<translation type="vanished">Kasutaja</translation>
<translation>Kasutaja</translation>
</message>
<message>
<source>Administrator</source>
<translation type="vanished">Administraator</translation>
<translation>Administraator</translation>
</message>
<message>
<source>User rights: </source>
<translation type="vanished">Kasutajaõigused: </translation>
<translation>Kasutajaõigused: </translation>
</message>
<message>
<source>Not found</source>
<translation type="vanished">Ei leitud</translation>
<translation>Ei leitud</translation>
</message>
<message>
<source>Certificate Propagation service status: </source>
<translation type="vanished">Certificate Propagation teenuse staatus: </translation>
<translation>Certificate Propagation teenuse staatus: </translation>
</message>
<message>
<source>is set manually</source>
Expand Down
16 changes: 6 additions & 10 deletions client/translations/ru.ts
Original file line number Diff line number Diff line change
Expand Up @@ -541,10 +541,6 @@
<source>Continue signing</source>
<translation>Подписать</translation>
</message>
<message>
<source>Cannot alter container %1. Save different location?</source>
<translation>Сохранение контейнера %1 не удалось. Сохранить в другой каталог?</translation>
</message>
<message>
<source>Encrypting</source>
<translation>Зашифровывание</translation>
Expand Down Expand Up @@ -697,27 +693,27 @@
</message>
<message>
<source>Unknown - error %1</source>
<translation type="vanished">Неизвестная - ошибка %1</translation>
<translation>Неизвестная - ошибка %1</translation>
</message>
<message>
<source>User</source>
<translation type="vanished">Пользователь</translation>
<translation>Пользователь</translation>
</message>
<message>
<source>Administrator</source>
<translation type="vanished">Администратор</translation>
<translation>Администратор</translation>
</message>
<message>
<source>User rights: </source>
<translation type="vanished">Права пользователя: </translation>
<translation>Права пользователя: </translation>
</message>
<message>
<source>Not found</source>
<translation type="vanished">Не найдено</translation>
<translation>Не найдено</translation>
</message>
<message>
<source>Certificate Propagation service status: </source>
<translation type="vanished">Статус Certificate Propagation сервиса: </translation>
<translation>Статус Certificate Propagation сервиса: </translation>
</message>
<message>
<source>is set manually</source>
Expand Down
Loading