Compare commits

...
Sign in to create a new pull request.

39 commits

Author SHA1 Message Date
Macbook
2c54fe7776 update 2024-10-24 19:12:49 +07:00
Macbook
d0b85813c7 final clean code 2024-10-13 17:06:56 +07:00
Macbook
484d33e922 test build Mac NE change build 2024-10-11 23:51:45 +07:00
Macbook
b3cd6e03a2 test build Mac NE change build 2024-10-11 23:38:56 +07:00
Macbook
1cdb8b33ee test build Mac NE change build 2024-10-11 23:14:16 +07:00
Macbook
e4679ff1fb test build Mac NE change build 2024-10-11 23:05:55 +07:00
Macbook
6ef03f9374 test build Mac NE change build 2024-10-11 22:58:15 +07:00
Macbook
e6c3ece85c test build Mac NE change build 2024-10-11 22:51:01 +07:00
Macbook
f8b951a428 test build Mac NE change build 2024-10-11 22:45:32 +07:00
Macbook
ea1a7e8701 test build Mac NE change build 2024-10-11 22:41:01 +07:00
Macbook
4700947fcb test build Mac NE change build 2024-10-11 22:27:36 +07:00
Macbook
e1d23c6738 test build Mac NE 2024-10-11 22:04:20 +07:00
Macbook
bfc2ac6c32 error: No profiles for NE 2024-10-10 20:49:45 +07:00
Macbook
9fc1df38cc add target 2024-10-10 17:33:27 +07:00
Macbook
336850624f input QT_PATH 2024-10-10 17:14:36 +07:00
Macbook
4287e5aa76 input QT_BIN_DIR 2024-10-10 17:08:22 +07:00
Macbook
c9b61f48cf input QT_BIN_DIR 2024-10-10 17:07:13 +07:00
Macbook
4c9a249695 chaneg version QT 2024-10-10 16:59:29 +07:00
Macbook
d0db1293b5 fix bug qt-cmake 2024-10-09 23:17:33 +07:00
Macbook
aaa8030348 fix bug qt-cmake 2024-10-09 23:15:55 +07:00
Macbook
3c3d4252f2 fix bug qt-cmake 2024-10-09 23:04:00 +07:00
Macbook
56d6ab2dd5 fix bug qt-cmake 2024-10-09 22:45:15 +07:00
Macbook
b93c5f3e57 fix bug qt-cmake 2024-10-09 22:41:32 +07:00
Macbook
9ddfa54352 fix bug QIF_VERSION 2024-10-09 22:31:53 +07:00
Macbook
1e893c2260 fix bug QT_BIN_DIR 2024-10-09 22:25:06 +07:00
Macbook
7d186c3c84 fix bug QT_BIN_DIR 2024-10-09 22:13:52 +07:00
Macbook
31938899a2 update build.sh 2024-10-09 21:59:25 +07:00
Macbook
b338a4fb79 update build.sh 2024-10-09 21:53:33 +07:00
Macbook
0500f1887c add qtmultimedia 2024-10-09 21:16:57 +07:00
Macbook
226f9b9316 add build ci/cd for macos ne 2024-10-09 21:04:35 +07:00
Macbook
ae16b19515 fix build on github 2024-10-09 20:44:00 +07:00
Macbook
5569524efa update all lib 2024-10-09 14:58:53 +07:00
Macbook
e2099b1682 clean source code 2024-10-08 21:33:36 +07:00
Macbook
022444ad63 Removed OpenVPNAdapter.bk submodule 2024-10-08 11:43:01 +07:00
Macbook
7da585fc27 update final code and cmake build file 2024-10-07 21:42:45 +07:00
Macbook
b1ad874f14 refactor code for iOS and MacNE 2024-10-06 23:07:21 +07:00
Macbook
f7aa82331e final build network extension 2024-10-05 11:16:57 +07:00
Macbook
b6601d051a error UIKet 2024-10-05 00:10:05 +07:00
Anh TV
1e60792f0c Merge to dev branch 2024-10-04 21:52:50 +07:00
71 changed files with 1993 additions and 346 deletions

View file

@ -294,6 +294,70 @@ jobs:
path: deploy/build/client/AmneziaVPN.app path: deploy/build/client/AmneziaVPN.app
retention-days: 7 retention-days: 7
# ------------------------------------------------------
Build-MacOS-NE:
runs-on: macos-latest
env:
QT_VERSION: 6.4.3
QIF_VERSION: 4.6
QT_MIRROR: https://mirrors.ocf.berkeley.edu/qt/
PROD_AGW_PUBLIC_KEY: ${{ secrets.PROD_AGW_PUBLIC_KEY }}
DEV_AGW_PUBLIC_KEY: ${{ secrets.DEV_AGW_PUBLIC_KEY }}
steps:
- name: 'Setup Xcode'
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '14.3.1'
- name: 'Install desktop Qt'
uses: jurplel/install-qt-action@v3
with:
version: ${{ env.QT_VERSION }}
host: 'mac'
target: 'desktop'
modules: 'qtremoteobjects qt5compat qtshadertools qtmultimedia'
arch: 'clang_64'
dir: ${{ runner.temp }}
set-env: 'true'
extra: '--base ${{ env.QT_MIRROR }}'
- name: 'Install Qt Installer Framework ${{ env.QIF_VERSION }}'
run: |
mkdir -pv ${{ runner.temp }}/Qt/Tools/QtInstallerFramework
wget https://qt.amzsvc.com/tools/ifw/${{ env.QIF_VERSION }}.zip
unzip ${{ env.QIF_VERSION }}.zip -d ${{ runner.temp }}/Qt/Tools/QtInstallerFramework/
- name: 'Install Go'
uses: actions/setup-go@v5
with:
go-version: '1.22.1'
cache: false
- name: 'Get sources'
uses: actions/checkout@v4
with:
submodules: 'true'
fetch-depth: 10
- name: 'Install dependencies'
run: pip install jsonschema jinja2
- name: 'Set execute permissions for deploy script'
run: chmod +x deploy/build_macos_ne.sh
- name: 'Build and deploy macOS NE'
run: |
export QT_BIN_DIR="${{ runner.temp }}/Qt/${{ env.QT_VERSION }}/macos/bin"
export QIF_BIN_DIR="${{ runner.temp }}/Qt/Tools/QtInstallerFramework/${{ env.QIF_VERSION }}/bin"
export QT_MACOS_ROOT_DIR="${{ runner.temp }}/Qt/${{ env.QT_VERSION }}/macos"
bash deploy/build_macos_ne.sh
env:
APPSTORE_CONNECT_KEY_ID: ${{ secrets.APPSTORE_CONNECT_KEY_ID }}
APPSTORE_CONNECT_ISSUER_ID: ${{ secrets.APPSTORE_CONNECT_ISSUER_ID }}
APPSTORE_CONNECT_PRIVATE_KEY: ${{ secrets.APPSTORE_CONNECT_PRIVATE_KEY }}
MAC_TRUST_CERT_BASE64: ${{ secrets.IOS_TRUST_CERT_BASE64 }}
MAC_SIGNING_CERT_BASE64: ${{ secrets.IOS_SIGNING_CERT_BASE64 }}
MAC_SIGNING_CERT_PASSWORD: ${{ secrets.IOS_SIGNING_CERT_PASSWORD }}
# ------------------------------------------------------ # ------------------------------------------------------
Build-Android: Build-Android:

2
.gitmodules vendored
View file

@ -1,6 +1,7 @@
[submodule "client/3rd/OpenVPNAdapter"] [submodule "client/3rd/OpenVPNAdapter"]
path = client/3rd/OpenVPNAdapter path = client/3rd/OpenVPNAdapter
url = https://github.com/amnezia-vpn/OpenVPNAdapter.git url = https://github.com/amnezia-vpn/OpenVPNAdapter.git
branch = macos-dirty-build
[submodule "client/3rd/qtkeychain"] [submodule "client/3rd/qtkeychain"]
path = client/3rd/qtkeychain path = client/3rd/qtkeychain
url = https://github.com/frankosterfeld/qtkeychain.git url = https://github.com/frankosterfeld/qtkeychain.git
@ -10,6 +11,7 @@
[submodule "client/3rd-prebuilt"] [submodule "client/3rd-prebuilt"]
path = client/3rd-prebuilt path = client/3rd-prebuilt
url = https://github.com/amnezia-vpn/3rd-prebuilt url = https://github.com/amnezia-vpn/3rd-prebuilt
branch = fixbug/mac-network-extension
[submodule "client/3rd/amneziawg-apple"] [submodule "client/3rd/amneziawg-apple"]
path = client/3rd/amneziawg-apple path = client/3rd/amneziawg-apple
url = https://github.com/amnezia-vpn/amneziawg-apple url = https://github.com/amnezia-vpn/amneziawg-apple

View file

@ -26,18 +26,20 @@ elseif(${CMAKE_SYSTEM_NAME} STREQUAL "iOS")
elseif(${CMAKE_SYSTEM_NAME} STREQUAL "Emscripten") elseif(${CMAKE_SYSTEM_NAME} STREQUAL "Emscripten")
set(MZ_PLATFORM_NAME "wasm") set(MZ_PLATFORM_NAME "wasm")
endif() endif()
message(STATUS "Platform: ${MZ_PLATFORM_NAME}")
message(STATUS "Version: ${MACOS_NE}")
set(QT_BUILD_TOOLS_WHEN_CROSS_COMPILING ON) set(QT_BUILD_TOOLS_WHEN_CROSS_COMPILING ON)
set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_STANDARD_REQUIRED ON)
if(APPLE AND NOT IOS) if((APPLE AND NOT IOS) OR (DEFINED MACOS_NE AND MACOS_NE AND NOT IOS))
set(CMAKE_OSX_ARCHITECTURES "x86_64") set(CMAKE_OSX_ARCHITECTURES "x86_64")
endif() endif()
add_subdirectory(client) add_subdirectory(client)
if(NOT IOS AND NOT ANDROID) # Mac OSX with Network Extension don't need service
if(NOT IOS AND NOT ANDROID AND NOT MACOS_NE)
add_subdirectory(service) add_subdirectory(service)
include(${CMAKE_SOURCE_DIR}/deploy/installer/config.cmake) include(${CMAKE_SOURCE_DIR}/deploy/installer/config.cmake)

@ -1 +1 @@
Subproject commit ba580dc5bd7784f7b1e110ff0365f3286e549a61 Subproject commit 435aaa793d8ce455ef4a3b2f5ff5e38f187d8efb

@ -1 +1 @@
Subproject commit 7c821a8d5c1ad5ad94e0763b4f25a875b5a6fe1b Subproject commit c3fa3e8f1c3ae92e3ebb39b38451a29aa79dbd01

@ -1 +1 @@
Subproject commit 76e7db556a6d7e2582f9481df91db188a46c009c Subproject commit 39ffdb6e71091bf5b5e456c02e6344a2d930b062

View file

@ -30,11 +30,12 @@ add_definitions(-DPROD_PROXY_STORAGE_KEY="$ENV{PROD_PROXY_STORAGE_KEY}")
add_definitions(-DDEV_AGW_PUBLIC_KEY="$ENV{DEV_AGW_PUBLIC_KEY}") add_definitions(-DDEV_AGW_PUBLIC_KEY="$ENV{DEV_AGW_PUBLIC_KEY}")
add_definitions(-DDEV_AGW_ENDPOINT="$ENV{DEV_AGW_ENDPOINT}") add_definitions(-DDEV_AGW_ENDPOINT="$ENV{DEV_AGW_ENDPOINT}")
if(IOS) if(IOS OR MACOS_NE)
set(PACKAGES ${PACKAGES} Multimedia) set(PACKAGES ${PACKAGES} Multimedia)
endif() endif()
if(WIN32 OR (APPLE AND NOT IOS) OR (LINUX AND NOT ANDROID)) #Macos Network Extension doesn't need Widgets
if(WIN32 OR (APPLE AND NOT IOS AND NOT MACOS_NE) OR (LINUX AND NOT ANDROID))
set(PACKAGES ${PACKAGES} Widgets) set(PACKAGES ${PACKAGES} Widgets)
endif() endif()
@ -47,18 +48,23 @@ set(LIBS ${LIBS}
Qt6::Core5Compat Qt6::Concurrent Qt6::Core5Compat Qt6::Concurrent
) )
if(IOS) if(IOS OR MACOS_NE)
set(LIBS ${LIBS} Qt6::Multimedia) set(LIBS ${LIBS} Qt6::Multimedia)
endif() endif()
# message("Client desktop build ", ${MACOS_NE})
#Macos Network Extension doesn't need Widgets
if(WIN32 OR (APPLE AND NOT IOS) OR (LINUX AND NOT ANDROID)) if(WIN32 OR (APPLE AND NOT IOS AND NOT MACOS_NE) OR (LINUX AND NOT ANDROID))
message("Run this block when MACOS_NE is not defined or set to FALSE")
set(LIBS ${LIBS} Qt6::Widgets) set(LIBS ${LIBS} Qt6::Widgets)
endif() endif()
qt_standard_project_setup() qt_standard_project_setup()
qt_add_executable(${PROJECT} MANUAL_FINALIZATION) qt_add_executable(${PROJECT} MANUAL_FINALIZATION)
if(WIN32 OR (APPLE AND NOT IOS) OR (LINUX AND NOT ANDROID)) # TODO error in there
if(WIN32 OR (APPLE AND NOT IOS AND NOT MACOS_NE) OR (LINUX AND NOT ANDROID))
message("Run this block when MACOS_NE is not defined or set to FALSE")
qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_interface.rep) qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_interface.rep)
qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_process_interface.rep) qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_process_interface.rep)
qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_process_tun2socks.rep) qt_add_repc_replicas(${PROJECT} ${CMAKE_CURRENT_LIST_DIR}/../ipc/ipc_process_tun2socks.rep)
@ -96,10 +102,18 @@ qt6_add_resources(QRC ${I18NQRC} ${CMAKE_CURRENT_BINARY_DIR}/translations.qrc)
# -- i18n end # -- i18n end
if(IOS) if(IOS)
message("Building for iOS")
execute_process(COMMAND bash ${CMAKE_CURRENT_LIST_DIR}/ios/scripts/openvpn.sh args execute_process(COMMAND bash ${CMAKE_CURRENT_LIST_DIR}/ios/scripts/openvpn.sh args
WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}) WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR})
endif() endif()
# Build openvpn adapter for MacOS Network Extension
if(MACOS_NE)
message("Building for MacOS Network Extension")
execute_process(COMMAND bash ${CMAKE_CURRENT_LIST_DIR}/macos/scripts/openvpn.sh args
WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR})
endif()
set(IS_CI ${CI}) set(IS_CI ${CI})
if(IS_CI) if(IS_CI)
message("Detected CI env") message("Detected CI env")
@ -160,12 +174,24 @@ include_directories(mozilla)
include_directories(mozilla/shared) include_directories(mozilla/shared)
include_directories(mozilla/models) include_directories(mozilla/models)
if(NOT IOS) if(MACOS_NE)
message("MACOS_NE is ON")
add_definitions(-DQ_OS_IOS)
add_definitions(-DMACOS_NE)
message("Add macros for MacOS Network Extension")
else()
message("MACOS_NE is OFF")
endif()
if(NOT IOS AND NOT MACOS_NE)
message(" Add header for non-IOS and non-MACOS_NE")
set(HEADERS ${HEADERS} set(HEADERS ${HEADERS}
${CMAKE_CURRENT_LIST_DIR}/platforms/ios/QRCodeReaderBase.h ${CMAKE_CURRENT_LIST_DIR}/platforms/ios/QRCodeReaderBase.h
) )
endif() endif()
if(NOT ANDROID) if(NOT ANDROID)
set(HEADERS ${HEADERS} set(HEADERS ${HEADERS}
${CMAKE_CURRENT_LIST_DIR}/ui/notificationhandler.h ${CMAKE_CURRENT_LIST_DIR}/ui/notificationhandler.h
@ -210,7 +236,7 @@ if(CMAKE_BUILD_TYPE STREQUAL "Debug")
target_compile_definitions(${PROJECT} PRIVATE "MZ_DEBUG") target_compile_definitions(${PROJECT} PRIVATE "MZ_DEBUG")
endif() endif()
if(NOT IOS) if(NOT IOS AND NOT MACOS_NE)
set(SOURCES ${SOURCES} set(SOURCES ${SOURCES}
${CMAKE_CURRENT_LIST_DIR}/platforms/ios/QRCodeReaderBase.cpp ${CMAKE_CURRENT_LIST_DIR}/platforms/ios/QRCodeReaderBase.cpp
) )
@ -318,10 +344,11 @@ if(LINUX AND NOT ANDROID)
link_directories(${CMAKE_CURRENT_LIST_DIR}/platforms/linux) link_directories(${CMAKE_CURRENT_LIST_DIR}/platforms/linux)
endif() endif()
if(WIN32 OR (APPLE AND NOT IOS) OR (LINUX AND NOT ANDROID)) # Macos Network Extension doesn't need
message("Client desktop build") if(WIN32 OR (APPLE AND NOT IOS AND NOT MACOS_NE) OR (LINUX AND NOT ANDROID))
message("-----> Client desktop build")
add_compile_definitions(AMNEZIA_DESKTOP) add_compile_definitions(AMNEZIA_DESKTOP)
message("-----> Add AMNEZIA_DESKTOP")
set(HEADERS ${HEADERS} set(HEADERS ${HEADERS}
${CMAKE_CURRENT_LIST_DIR}/core/ipcclient.h ${CMAKE_CURRENT_LIST_DIR}/core/ipcclient.h
${CMAKE_CURRENT_LIST_DIR}/core/privileged_process.h ${CMAKE_CURRENT_LIST_DIR}/core/privileged_process.h
@ -354,9 +381,12 @@ endif()
if(IOS) if(IOS)
include(cmake/ios.cmake) include(cmake/ios.cmake)
include(cmake/ios-arch-fixup.cmake) include(cmake/ios-arch-fixup.cmake)
elseif(APPLE AND NOT IOS) elseif(APPLE AND NOT IOS AND NOT DEFINED MACOS_NE)
include(cmake/osxtools.cmake) # include(cmake/osxtools.cmake)
include(cmake/macos.cmake) include(cmake/macos.cmake)
elseif(APPLE AND NOT IOS AND MACOS_NE)
include(cmake/osxtools.cmake)
include(cmake/macos_ne.cmake)
endif() endif()
target_link_libraries(${PROJECT} PRIVATE ${LIBS}) target_link_libraries(${PROJECT} PRIVATE ${LIBS})
@ -375,7 +405,7 @@ elseif(APPLE AND NOT IOS)
set(DEPLOY_PLATFORM_PATH "macos") set(DEPLOY_PLATFORM_PATH "macos")
endif() endif()
if(NOT IOS AND NOT ANDROID) if(NOT IOS AND NOT ANDROID AND NOT MACOS_NE)
add_custom_command( add_custom_command(
TARGET ${PROJECT} POST_BUILD TARGET ${PROJECT} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E $<IF:$<CONFIG:Debug>,copy_directory,true> COMMAND ${CMAKE_COMMAND} -E $<IF:$<CONFIG:Debug>,copy_directory,true>
@ -394,4 +424,36 @@ if(NOT IOS AND NOT ANDROID)
endif() endif()
target_sources(${PROJECT} PRIVATE ${SOURCES} ${HEADERS} ${RESOURCES} ${QRC} ${I18NQRC}) target_sources(${PROJECT} PRIVATE ${SOURCES} ${HEADERS} ${RESOURCES} ${QRC} ${I18NQRC})
if(MACOS_NE)
message("Copy MacOS Network Extension files")
message("QT_HOST_PATH: $ENV{QT_MACOS_ROOT_DIR}")
add_custom_command(TARGET ${PROJECT} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E make_directory
"$<TARGET_BUNDLE_DIR:AmneziaVPN>/Contents/Frameworks"
COMMAND ${CMAKE_COMMAND} -E copy_directory
"$ENV{QT_MACOS_ROOT_DIR}/lib/QtConcurrent.framework"
"$<TARGET_BUNDLE_DIR:AmneziaVPN>/Contents/Frameworks/QtConcurrent.framework"
COMMENT "Copying QtConcurrent.framework from QT_MACOS_ROOT_DIR to the bundle's Frameworks directory"
)
# MacOS specific application deployment
add_custom_command(TARGET ${PROJECT} POST_BUILD
COMMAND ${QT_BIN_DIR_DETECTED}/macdeployqt $<TARGET_BUNDLE_DIR:AmneziaVPN> -appstore-compliant -qmldir=${CMAKE_CURRENT_SOURCE_DIR}
)
# MacOS specific code signing for Release
if(CMAKE_BUILD_TYPE STREQUAL "Release")
SET(SIGN_CMD codesign --deep --force --sign 'Apple Distribution: Privacy Technologies OU \(X7UJ388FXK\)' --timestamp --options runtime $<TARGET_BUNDLE_DIR:AmneziaVPN>)
message("Manual signing bundle...")
message(${SIGN_CMD})
add_custom_command(TARGET ${PROJECT} POST_BUILD
COMMAND ${SIGN_CMD}
)
endif()
endif()
qt_finalize_target(${PROJECT}) qt_finalize_target(${PROJECT})

181
client/cmake/macos_ne.cmake Normal file
View file

@ -0,0 +1,181 @@
message("Client ==> MacOS NE build")
set_target_properties(${PROJECT} PROPERTIES MACOSX_BUNDLE TRUE)
set(CMAKE_OSX_ARCHITECTURES "x86_64" CACHE INTERNAL "" FORCE)
set(CMAKE_OSX_DEPLOYMENT_TARGET 10.15)
set(APPLE_PROJECT_VERSION ${CMAKE_PROJECT_VERSION_MAJOR}.${CMAKE_PROJECT_VERSION_MINOR}.${CMAKE_PROJECT_VERSION_PATCH})
enable_language(OBJC)
# enable_language(OBJCXX)
enable_language(Swift)
find_package(Qt6 REQUIRED COMPONENTS ShaderTools)
set(LIBS ${LIBS} Qt6::ShaderTools)
find_library(FW_AUTHENTICATIONSERVICES AuthenticationServices)
#find_library(FW_UIKIT UIKit)
find_library(FW_AVFOUNDATION AVFoundation)
find_library(FW_FOUNDATION Foundation)
find_library(FW_STOREKIT StoreKit)
find_library(FW_USERNOTIFICATIONS UserNotifications)
find_library(FW_NETWORKEXTENSION NetworkExtension)
set(LIBS ${LIBS}
${FW_AUTHENTICATIONSERVICES}
# ${FW_UIKIT}
${FW_AVFOUNDATION}
${FW_FOUNDATION}
${FW_STOREKIT}
${FW_USERNOTIFICATIONS}
${FW_NETWORKEXTENSION}
)
set(HEADERS ${HEADERS}
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/ios_controller.h
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/ios_controller_wrapper.h
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/iosnotificationhandler.h
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/QtAppDelegate.h
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/QtAppDelegate-C-Interface.h
)
set_source_files_properties(${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/ios_controller.h PROPERTIES OBJECTIVE_CPP_HEADER TRUE)
set(SOURCES ${SOURCES}
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/ios_controller.mm
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/ios_controller_wrapper.mm
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/iosnotificationhandler.mm
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/iosglue.mm
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/QRCodeReaderBase.mm
${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/QtAppDelegate.mm
)
set(ICON_FILE ${CMAKE_CURRENT_SOURCE_DIR}/images/app.icns)
set(MACOSX_BUNDLE_ICON_FILE app.icns)
set_source_files_properties(${ICON_FILE} PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
set(SOURCES ${SOURCES} ${ICON_FILE})
# set(HEADERS ${HEADERS}
# ${CMAKE_CURRENT_SOURCE_DIR}/ui/macos_util.h
# )
# set(SOURCES ${SOURCES}
# ${CMAKE_CURRENT_SOURCE_DIR}/ui/macos_util.mm
# )
target_include_directories(${PROJECT} PRIVATE ${Qt6Gui_PRIVATE_INCLUDE_DIRS})
set_target_properties(${PROJECT} PROPERTIES
XCODE_LINK_BUILD_PHASE_MODE KNOWN_LOCATION
MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/macos/app/Info.plist.in
#MACOSX_BUNDLE_ICON_FILE "AppIcon"
MACOSX_BUNDLE_INFO_STRING "AmneziaVPN"
MACOSX_BUNDLE_BUNDLE_NAME "AmneziaVPN"
MACOSX_BUNDLE_BUNDLE_VERSION "${CMAKE_PROJECT_VERSION_TWEAK}"
MACOSX_BUNDLE_LONG_VERSION_STRING "${APPLE_PROJECT_VERSION}-${CMAKE_PROJECT_VERSION_TWEAK}"
MACOSX_BUNDLE_SHORT_VERSION_STRING "${APPLE_PROJECT_VERSION}"
XCODE_ATTRIBUTE_PRODUCT_BUNDLE_IDENTIFIER "${BUILD_IOS_APP_IDENTIFIER}"
XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS "${CMAKE_CURRENT_SOURCE_DIR}/macos/app/main.entitlements"
XCODE_ATTRIBUTE_MARKETING_VERSION "${APPLE_PROJECT_VERSION}"
XCODE_ATTRIBUTE_CURRENT_PROJECT_VERSION "${CMAKE_PROJECT_VERSION_TWEAK}"
XCODE_ATTRIBUTE_PRODUCT_NAME "AmneziaVPN"
XCODE_ATTRIBUTE_BUNDLE_INFO_STRING "AmneziaVPN"
XCODE_GENERATE_SCHEME TRUE
XCODE_ATTRIBUTE_ENABLE_BITCODE "NO"
#XCODE_ATTRIBUTE_ASSETCATALOG_COMPILER_APPICON_NAME "AppIcon"
XCODE_ATTRIBUTE_TARGETED_DEVICE_FAMILY "1,2"
XCODE_EMBED_FRAMEWORKS_CODE_SIGN_ON_COPY "NO"
XCODE_EMBED_FRAMEWORKS_REMOVE_HEADERS_ON_COPY "YES"
XCODE_LINK_BUILD_PHASE_MODE KNOWN_LOCATION
XCODE_ATTRIBUTE_LD_RUNPATH_SEARCH_PATHS "@executable_path/../Frameworks"
XCODE_EMBED_APP_EXTENSIONS networkextension
XCODE_ATTRIBUTE_CODE_SIGN_STYLE Automatic
# XCODE_ATTRIBUTE_CODE_SIGN_STYLE Manual
# XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "Apple Distribution: Privacy Technologies OU (X7UJ388FXK)"
# XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY[variant=Debug] "Apple Development"
# XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER "Mac AppStore AmneziaVPN"
# XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER[variant=Debug] "Mac AppStore AmneziaVPN"
)
set_target_properties(${PROJECT} PROPERTIES
XCODE_ATTRIBUTE_SWIFT_VERSION "5.0"
XCODE_ATTRIBUTE_CLANG_ENABLE_MODULES "YES"
XCODE_ATTRIBUTE_SWIFT_PRECOMPILE_BRIDGING_HEADER "NO"
XCODE_ATTRIBUTE_SWIFT_OBJC_INTERFACE_HEADER_NAME "AmneziaVPN-Swift.h"
XCODE_ATTRIBUTE_SWIFT_OBJC_INTEROP_MODE "objcxx"
)
set_target_properties(${PROJECT} PROPERTIES
XCODE_ATTRIBUTE_DEVELOPMENT_TEAM "X7UJ388FXK"
)
target_include_directories(${PROJECT} PRIVATE ${CMAKE_CURRENT_LIST_DIR})
target_compile_options(${PROJECT} PRIVATE
-DGROUP_ID=\"${BUILD_IOS_GROUP_IDENTIFIER}\"
-DVPN_NE_BUNDLEID=\"${BUILD_IOS_APP_IDENTIFIER}.network-extension\"
)
set(WG_APPLE_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/3rd/amneziawg-apple/Sources)
target_sources(${PROJECT} PRIVATE
# ${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios/iosvpnprotocol.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKitC/x25519.c
${CLIENT_ROOT_DIR}/platforms/ios/LogController.swift
${CLIENT_ROOT_DIR}/platforms/ios/Log.swift
${CLIENT_ROOT_DIR}/platforms/ios/LogRecord.swift
${CLIENT_ROOT_DIR}/platforms/ios/ScreenProtection.swift
${CLIENT_ROOT_DIR}/platforms/ios/VPNCController.swift
)
target_sources(${PROJECT} PRIVATE
#${CMAKE_CURRENT_SOURCE_DIR}/macos_ne/app/AmneziaVPNLaunchScreen.storyboard
${CMAKE_CURRENT_SOURCE_DIR}/macos/app/Media.xcassets
${CMAKE_CURRENT_SOURCE_DIR}/macos/app/PrivacyInfo.xcprivacy
)
set_property(TARGET ${PROJECT} APPEND PROPERTY RESOURCE
#${CMAKE_CURRENT_SOURCE_DIR}/macos/app/AmneziaVPNLaunchScreen.storyboard
${CMAKE_CURRENT_SOURCE_DIR}/macos/app/Media.xcassets
${CMAKE_CURRENT_SOURCE_DIR}/macos/app/PrivacyInfo.xcprivacy
)
add_subdirectory(macos/networkextension)
add_dependencies(${PROJECT} networkextension)
# set_property(TARGET ${PROJECT} PROPERTY XCODE_EMBED_FRAMEWORKS
# "${CMAKE_CURRENT_SOURCE_DIR}/3rd/OpenVPNAdapter/build/Release-iphoneos/OpenVPNAdapter.framework"
# )
# set(CMAKE_XCODE_ATTRIBUTE_FRAMEWORK_SEARCH_PATHS ${CMAKE_CURRENT_SOURCE_DIR}/3rd/OpenVPNAdapter/build/Release-iphoneos)
# target_link_libraries("networkextension" PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/3rd/OpenVPNAdapter/build/Release-iphoneos/OpenVPNAdapter.framework")
get_target_property(QtCore_location Qt6::Core LOCATION)
message("QtCore_location")
message(${QtCore_location})
get_filename_component(QT_BIN_DIR_DETECTED "${QtCore_location}/../../../../../bin" ABSOLUTE)
# add_custom_command(TARGET ${PROJECT} POST_BUILD
# COMMAND ${QT_BIN_DIR_DETECTED}/macdeployqt $<TARGET_BUNDLE_DIR:AmneziaVPN> -appstore-compliant -qmldir=${CMAKE_CURRENT_SOURCE_DIR}
# )
# if(CMAKE_BUILD_TYPE STREQUAL "Release")
# SET(SIGN_CMD codesign --deep --force --sign 'Apple Distribution: Privacy Technologies OU \(X7UJ388FXK\)' --timestamp --options runtime $<TARGET_BUNDLE_DIR:AmneziaVPN>)
# message("Manual signing bundle...")
# message(${SIGN_CMD})
# add_custom_command(TARGET ${PROJECT} POST_BUILD
# COMMAND ${SIGN_CMD}
# )
# endif()

View file

@ -76,7 +76,7 @@ function(osx_bundle_assetcatalog TARGET)
) )
## Patch the asset catalog into the target bundle. ## Patch the asset catalog into the target bundle.
if(NOT IOS) if(NOT IOS AND NOT MACOS_NE)
set(XCASSETS_RESOURCE_DIR "Resources") set(XCASSETS_RESOURCE_DIR "Resources")
endif() endif()
add_custom_command(TARGET ${TARGET} POST_BUILD add_custom_command(TARGET ${TARGET} POST_BUILD
@ -141,6 +141,7 @@ function(osx_codesign_target TARGET)
endif() endif()
foreach(FILE ${CODESIGN_FILES}) foreach(FILE ${CODESIGN_FILES})
message(STATUS "Signing ${TARGET}: ${FILE}")
add_custom_command(TARGET ${TARGET} POST_BUILD VERBATIM add_custom_command(TARGET ${TARGET} POST_BUILD VERBATIM
COMMAND ${COMMENT_ECHO_COMMAND} "Signing ${TARGET}: ${FILE}" COMMAND ${COMMENT_ECHO_COMMAND} "Signing ${TARGET}: ${FILE}"
COMMAND ${CODESIGN_BIN} ${CODESIGN_ARGS} ${FILE} COMMAND ${CODESIGN_BIN} ${CODESIGN_ARGS} ${FILE}

View file

@ -102,7 +102,9 @@ QProcessEnvironment SshConfigurator::prepareEnv()
pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "\\cygwin;"); pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "\\cygwin;");
pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "\\openvpn;"); pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "\\openvpn;");
#elif defined(Q_OS_MACX) #elif defined(Q_OS_MACX)
#if !defined(MACOS_NE)
pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "/Contents/MacOS"); pathEnvVar.prepend(QDir::toNativeSeparators(QApplication::applicationDirPath()) + "/Contents/MacOS");
#endif
#endif #endif
env.insert("PATH", pathEnvVar); env.insert("PATH", pathEnvVar);

View file

@ -0,0 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="17506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
<device id="ipad12_9rounded" orientation="portrait" layout="fullscreen" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17505"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="gZ9-gc-3t5">
<rect key="frame" x="0.0" y="0.0" width="1024" height="1366"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="launch.png" translatesAutoresizingMaskIntoConstraints="NO" id="q5g-aV-39U">
<rect key="frame" x="467" y="638" width="90" height="90"/>
<constraints>
<constraint firstAttribute="width" constant="90" id="VFp-nz-h8O"/>
<constraint firstAttribute="height" constant="90" id="ZUg-Ud-mgE"/>
</constraints>
</imageView>
</subviews>
<viewLayoutGuide key="safeArea" id="Whf-X3-AA4"/>
<color key="backgroundColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="q5g-aV-39U" firstAttribute="centerX" secondItem="gZ9-gc-3t5" secondAttribute="centerX" id="Ayw-bo-LVF"/>
<constraint firstItem="q5g-aV-39U" firstAttribute="centerY" secondItem="gZ9-gc-3t5" secondAttribute="centerY" id="YHd-Kc-J0u"/>
</constraints>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="53" y="375"/>
</scene>
</scenes>
<resources>
<image name="launch.png" width="1024" height="1024"/>
</resources>
</document>

View file

@ -0,0 +1,178 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleAllowMixedLocalizations</key>
<true/>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>${QT_INTERNAL_DOLLAR_VAR}{PRODUCT_NAME}</string>
<key>CFBundleExecutable</key>
<string>${MACOSX_BUNDLE_EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
<string>${MACOSX_BUNDLE_GUI_IDENTIFIER}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${MACOSX_BUNDLE_BUNDLE_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>${MACOSX_BUNDLE_SHORT_VERSION_STRING}</string>
<key>CFBundleVersion</key>
<string>${MACOSX_BUNDLE_BUNDLE_VERSION}</string>
<key>NSHumanReadableCopyright</key>
<string>${MACOSX_BUNDLE_COPYRIGHT}</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>LSSupportsOpeningDocumentsInPlace</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>AmneziaVPNLaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
<array/>
<key>UIRequiresFullScreen</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationPortrait</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array/>
<key>UIUserInterfaceStyle</key>
<string>Light</string>
<key>com.wireguard.ios.app_group_id</key>
<string>group.org.amnezia.AmneziaVPN</string>
<key>UIViewControllerBasedStatusBarAppearance</key>
<true/>
<key>NSCameraUsageDescription</key>
<string>Amnezia VPN needs access to the camera for reading QR-codes.</string>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<false/>
<key>NSAllowsLocalNetworking</key>
<true/>
</dict>
<key>CFBundleIcons</key>
<dict/>
<key>CFBundleIcons~ipad</key>
<dict/>
<key>UTImportedTypeDeclarations</key>
<array>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>public.data</string>
</array>
<key>UTTypeDescription</key>
<string>Amnezia VPN config</string>
<key>UTTypeIconFiles</key>
<array/>
<key>UTTypeIdentifier</key>
<string>org.amnezia.AmneziaVPN.amnezia-config</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>vpn</string>
</array>
<key>public.mime-type</key>
<array>
<string>text/plain</string>
</array>
</dict>
</dict>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>public.data</string>
</array>
<key>UTTypeDescription</key>
<string>WireGuard config</string>
<key>UTTypeIconFiles</key>
<array/>
<key>UTTypeIdentifier</key>
<string>org.amnezia.AmneziaVPN.wireguard-config</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>conf</string>
<string>cfg</string>
</array>
<key>public.mime-type</key>
<array>
<string>text/plain</string>
</array>
</dict>
</dict>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>public.data</string>
</array>
<key>UTTypeDescription</key>
<string>OpenVPN config</string>
<key>UTTypeIconFiles</key>
<array/>
<key>UTTypeIdentifier</key>
<string>org.amnezia.AmneziaVPN.openvpn-config</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>ovpn</string>
</array>
<key>public.mime-type</key>
<array>
<string>text/plain</string>
</array>
</dict>
</dict>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>public.data</string>
</array>
<key>UTTypeDescription</key>
<string>AmneziaVPN backup file</string>
<key>UTTypeIconFiles</key>
<array/>
<key>UTTypeIdentifier</key>
<string>org.amnezia.AmneziaVPN.backup-config</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>backup</string>
</array>
<key>public.mime-type</key>
<array>
<string>text/plain</string>
</array>
</dict>
</dict>
</array>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeName</key>
<string>Amnezia VPN config</string>
<key>LSHandlerRank</key>
<string>Alternate</string>
<key>LSItemContentTypes</key>
<array>
<string>org.amnezia.AmneziaVPN.amnezia-config</string>
<string>org.amnezia.AmneziaVPN.wireguard-config</string>
<string>org.amnezia.AmneziaVPN.openvpn-config</string>
<string>org.amnezia.AmneziaVPN.backup-config</string>
</array>
</dict>
</array>
</dict>
</plist>

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 767 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

View file

@ -0,0 +1,290 @@
{
"images" : [
{
"filename" : "40.png",
"idiom" : "iphone",
"scale" : "2x",
"size" : "20x20"
},
{
"filename" : "60.png",
"idiom" : "iphone",
"scale" : "3x",
"size" : "20x20"
},
{
"filename" : "29.png",
"idiom" : "iphone",
"scale" : "1x",
"size" : "29x29"
},
{
"filename" : "58.png",
"idiom" : "iphone",
"scale" : "2x",
"size" : "29x29"
},
{
"filename" : "87.png",
"idiom" : "iphone",
"scale" : "3x",
"size" : "29x29"
},
{
"filename" : "80.png",
"idiom" : "iphone",
"scale" : "2x",
"size" : "40x40"
},
{
"filename" : "120.png",
"idiom" : "iphone",
"scale" : "3x",
"size" : "40x40"
},
{
"filename" : "57.png",
"idiom" : "iphone",
"scale" : "1x",
"size" : "57x57"
},
{
"filename" : "114.png",
"idiom" : "iphone",
"scale" : "2x",
"size" : "57x57"
},
{
"filename" : "120.png",
"idiom" : "iphone",
"scale" : "2x",
"size" : "60x60"
},
{
"filename" : "180.png",
"idiom" : "iphone",
"scale" : "3x",
"size" : "60x60"
},
{
"filename" : "20.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "20x20"
},
{
"filename" : "40.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "20x20"
},
{
"filename" : "29.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "29x29"
},
{
"filename" : "58.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "29x29"
},
{
"filename" : "40.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "40x40"
},
{
"filename" : "80.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "40x40"
},
{
"filename" : "50.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "50x50"
},
{
"filename" : "100.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "50x50"
},
{
"filename" : "72.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "72x72"
},
{
"filename" : "144.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "72x72"
},
{
"filename" : "76.png",
"idiom" : "ipad",
"scale" : "1x",
"size" : "76x76"
},
{
"filename" : "152.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "76x76"
},
{
"filename" : "167.png",
"idiom" : "ipad",
"scale" : "2x",
"size" : "83.5x83.5"
},
{
"filename" : "1024.png",
"idiom" : "ios-marketing",
"scale" : "1x",
"size" : "1024x1024"
},
{
"idiom" : "watch",
"role" : "notificationCenter",
"scale" : "2x",
"size" : "24x24",
"subtype" : "38mm"
},
{
"idiom" : "watch",
"role" : "notificationCenter",
"scale" : "2x",
"size" : "27.5x27.5",
"subtype" : "42mm"
},
{
"idiom" : "watch",
"role" : "companionSettings",
"scale" : "2x",
"size" : "29x29"
},
{
"idiom" : "watch",
"role" : "companionSettings",
"scale" : "3x",
"size" : "29x29"
},
{
"idiom" : "watch",
"role" : "notificationCenter",
"scale" : "2x",
"size" : "33x33",
"subtype" : "45mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "40x40",
"subtype" : "38mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "44x44",
"subtype" : "40mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "46x46",
"subtype" : "41mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "50x50",
"subtype" : "44mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "51x51",
"subtype" : "45mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "54x54",
"subtype" : "49mm"
},
{
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "86x86",
"subtype" : "38mm"
},
{
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "98x98",
"subtype" : "42mm"
},
{
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "108x108",
"subtype" : "44mm"
},
{
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "117x117",
"subtype" : "45mm"
},
{
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "129x129",
"subtype" : "49mm"
},
{
"idiom" : "watch-marketing",
"scale" : "1x",
"size" : "1024x1024"
},
{
"idiom" : "car",
"scale" : "2x",
"size" : "60"
},
{
"idiom" : "car",
"scale" : "3x",
"size" : "60"
},
{
"idiom" : "watch",
"role" : "longLook",
"scale" : "2x",
"size" : "44x44",
"subtype" : "42mm"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

View file

@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View file

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>1C8F.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategorySystemBootTime</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>35F9.1</string>
</array>
</dict>
</array>
</dict>
</plist>

BIN
client/macos/app/launch.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 583 KiB

View file

@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.developer.networking.networkextension</key>
<array>
<string>packet-tunnel-provider</string>
</array>
<key>com.apple.security.application-groups</key>
<array>
<string>group.org.amnezia.AmneziaVPN</string>
</array>
<key>com.apple.security.files.user-selected.read-write</key>
<true/>
<key>keychain-access-groups</key>
<array>
<string>$(AppIdentifierPrefix)group.org.amnezia.AmneziaVPN</string>
</array>
</dict>
</plist>

View file

@ -3,40 +3,26 @@
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>com.apple.application-identifier</key> <key>com.apple.application-identifier</key>
<string>$(DEVELOPMENT_TEAM).$(NETEXT_ID_MACOS)</string> <string>X7UJ388FXK.org.amnezia.AmneziaVPN.network-extension</string>
<key>com.apple.developer.networking.networkextension</key> <key>com.apple.developer.networking.networkextension</key>
<array> <array>
<string>packet-tunnel-provider</string> <string>packet-tunnel-provider</string>
</array> </array>
<key>keychain-access-groups</key>
<array>
<string>$(DEVELOPMENT_TEAM).*</string>
</array>
<key>com.apple.developer.team-identifier</key> <key>com.apple.developer.team-identifier</key>
<string>$(DEVELOPMENT_TEAM)</string> <string>X7UJ388FXK</string>
<key>com.apple.developer.system-extension.install</key>
<true/>
<key>com.apple.security.app-sandbox</key> <key>com.apple.security.app-sandbox</key>
<true/> <true/>
<key>com.apple.security.application-groups</key> <key>com.apple.security.application-groups</key>
<array> <array>
<string>$(DEVELOPMENT_TEAM).$(GROUP_ID_MACOS)</string> <string>group.org.amnezia.AmneziaVPN</string>
</array> </array>
<key>com.apple.security.network.client</key> <key>com.apple.security.network.client</key>
<true/> <true/>
<key>com.apple.security.network.server</key> <key>com.apple.security.network.server</key>
<true/> <true/>
<key>com.apple.security.app-sandbox</key> <key>keychain-access-groups</key>
<true/> <array>
<key>com.apple.private.network.socket-delegate</key> <string>$(AppIdentifierPrefix)org.amnezia.AmneziaVPN.network-extension</string>
<true/> </array>
</dict> </dict>
</plist> </plist>

View file

@ -0,0 +1,207 @@
enable_language(Swift)
message("Client message >> macos build >> networkextension")
set(CLIENT_ROOT_DIR ${CMAKE_CURRENT_LIST_DIR}/../..)
add_executable(networkextension)
configure_file(
${CMAKE_CURRENT_LIST_DIR}/Info.plist.in
${CMAKE_CURRENT_BINARY_DIR}/Info.plist
)
if(MACOS_NE)
message("MACOS_NE is ON")
add_definitions(-DQ_OS_IOS)
add_definitions(-DMACOS_NE)
message("Add macros for MacOS Network Extension")
else()
message("MACOS_NE is OFF")
endif()
set_target_properties(networkextension PROPERTIES
XCODE_PRODUCT_TYPE com.apple.product-type.app-extension
BUNDLE_EXTENSION appex
#MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_BINARY_DIR}/Info.plist
MACOSX_BUNDLE_SHORT_VERSION_STRING "${APPLE_PROJECT_VERSION}"
XCODE_ATTRIBUTE_PRODUCT_BUNDLE_IDENTIFIER "${BUILD_IOS_APP_IDENTIFIER}.network-extension"
XCODE_ATTRIBUTE_PRODUCT_BUNDLE_NAME "${BUILD_IOS_APP_IDENTIFIER}.network-extension"
XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS ${CMAKE_CURRENT_SOURCE_DIR}/AmneziaVPNNetworkExtension.entitlements
XCODE_ATTRIBUTE_MARKETING_VERSION "${APP_MAJOR_VERSION}"
XCODE_ATTRIBUTE_CURRENT_PROJECT_VERSION "${BUILD_ID}"
XCODE_ATTRIBUTE_PRODUCT_NAME "AmneziaVPNNetworkExtension"
XCODE_ATTRIBUTE_APPLICATION_EXTENSION_API_ONLY "YES"
XCODE_ATTRIBUTE_ENABLE_BITCODE "NO"
XCODE_ATTRIBUTE_TARGETED_DEVICE_FAMILY "1,2"
XCODE_ATTRIBUTE_LD_RUNPATH_SEARCH_PATHS "@executable_path/../../Frameworks"
XCODE_ATTRIBUTE_CODE_SIGN_STYLE Automatic
# #XCODE_ATTRIBUTE_CODE_SIGN_STYLE Manual
# #XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "Apple Distribution: Privacy Technologies OU (X7UJ388FXK)"
# #XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY[variant=Debug] "Apple Development"
# #XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER "Mac AppStore AmneziaVPN.network-extension"
# #XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER[variant=Debug] "Mac AppStore AmneziaVPN.network-extension"
XCODE_ATTRIBUTE_INFOPLIST_FILE "${CMAKE_CURRENT_BINARY_DIR}/Info.plist"
XCODE_ATTRIBUTE_LD_RUNPATH_SEARCH_PATHS "@executable_path/../../../../Frameworks @loader_path/../../../../Frameworks"
)
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
set_target_properties(networkextension PROPERTIES
XCODE_ATTRIBUTE_CODE_SIGN_STYLE Automatic
)
endif()
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set_target_properties(networkextension PROPERTIES
XCODE_ATTRIBUTE_CODE_SIGN_STYLE Automatic
#XCODE_ATTRIBUTE_CODE_SIGN_STYLE Manual
#XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "Apple Distribution: Privacy Technologies OU (X7UJ388FXK)"
#XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY[variant=Debug] "Apple Development"
#XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER "Mac AppStore AmneziaVPN.network-extension"
#XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER[variant=Debug] "Mac AppStore AmneziaVPN.network-extension"
)
endif()
set_target_properties(networkextension PROPERTIES
XCODE_ATTRIBUTE_SWIFT_VERSION "5.0"
XCODE_ATTRIBUTE_CLANG_ENABLE_MODULES "YES"
XCODE_ATTRIBUTE_SWIFT_OBJC_BRIDGING_HEADER "${CMAKE_CURRENT_SOURCE_DIR}/WireGuardNetworkExtension-Bridging-Header.h"
XCODE_ATTRIBUTE_SWIFT_OPTIMIZATION_LEVEL "-Onone"
XCODE_ATTRIBUTE_SWIFT_PRECOMPILE_BRIDGING_HEADER "NO"
)
set_target_properties("networkextension" PROPERTIES
XCODE_ATTRIBUTE_DEVELOPMENT_TEAM "X7UJ388FXK"
)
find_library(FW_ASSETS_LIBRARY AssetsLibrary)
find_library(FW_MOBILE_CORE MobileCoreServices)
find_library(FW_UI_KIT UIKit)
find_library(FW_LIBRESOLV libresolv.9.tbd)
# set(OpenVPNAdapter_DIR "${CLIENT_ROOT_DIR}/3rd/")
# find_library(OPENVPN_ADAPTER_LIBRARY OpenVPNAdapter PATHS ${OpenVPNAdapter_DIR})
# target_link_libraries(networkextension PRIVATE ${OPENVPN_ADAPTER_LIBRARY})
# add_custom_command(TARGET networkextension PRE_BUILD
# COMMAND ${CMAKE_COMMAND} -E make_directory $<TARGET_FILE_DIR:networkextension>/../Frameworks
# )
# add_custom_command(TARGET networkextension POST_BUILD
# COMMAND ${CMAKE_COMMAND} -E echo "Copying ${OPENVPN_ADAPTER_LIBRARY} to $<TARGET_FILE_DIR:networkextension>/../Frameworks/"
# COMMAND ${CMAKE_COMMAND} -E copy_if_different
# ${OPENVPN_ADAPTER_LIBRARY}
# $<TARGET_FILE_DIR:networkextension>/../Frameworks/
# COMMAND ${CMAKE_COMMAND} -E echo "Copy complete"
# )
# Set the root directory
set(CLIENT_ROOT_DIR ${CMAKE_CURRENT_LIST_DIR}/../..)
# Embedding the framework using CLIENT_ROOT_DIR
set_property(TARGET networkextension PROPERTY XCODE_EMBED_FRAMEWORKS
"${CLIENT_ROOT_DIR}/3rd/OpenVPNAdapter/build/Release-macos/OpenVPNAdapter.framework"
)
# Setting the framework search paths using CLIENT_ROOT_DIR
set(CMAKE_XCODE_ATTRIBUTE_FRAMEWORK_SEARCH_PATHS "${CLIENT_ROOT_DIR}/3rd/OpenVPNAdapter/build/Release-macos")
# Linking the framework using CLIENT_ROOT_DIR
target_link_libraries("networkextension" PRIVATE "${CLIENT_ROOT_DIR}/3rd/OpenVPNAdapter/build/Release-macos/OpenVPNAdapter.framework")
#target_link_libraries(networkextension PRIVATE ${FW_ASSETS_LIBRARY})
#target_link_libraries(networkextension PRIVATE ${FW_MOBILE_CORE})
#target_link_libraries(networkextension PRIVATE ${FW_UI_KIT})
target_link_libraries(networkextension PRIVATE ${FW_LIBRESOLV})
target_compile_options(networkextension PRIVATE -DGROUP_ID=\"${BUILD_IOS_GROUP_IDENTIFIER}\")
target_compile_options(networkextension PRIVATE -DNETWORK_EXTENSION=1)
set(WG_APPLE_SOURCE_DIR ${CLIENT_ROOT_DIR}/3rd/amneziawg-apple/Sources)
message("WG_APPLE_SOURCE_DIR is: ${WG_APPLE_SOURCE_DIR}")
message("CLIENT_ROOT_DIR is: ${CLIENT_ROOT_DIR}")
target_sources(networkextension PRIVATE
${WG_APPLE_SOURCE_DIR}/WireGuardKit/WireGuardAdapter.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/PacketTunnelSettingsGenerator.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/DNSResolver.swift
${WG_APPLE_SOURCE_DIR}/WireGuardNetworkExtension/ErrorNotifier.swift
${WG_APPLE_SOURCE_DIR}/Shared/Keychain.swift
${WG_APPLE_SOURCE_DIR}/Shared/Model/TunnelConfiguration+WgQuickConfig.swift
${WG_APPLE_SOURCE_DIR}/Shared/Model/NETunnelProviderProtocol+Extension.swift
${WG_APPLE_SOURCE_DIR}/Shared/Model/String+ArrayConversion.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/TunnelConfiguration.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/IPAddressRange.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/Endpoint.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/DNSServer.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/InterfaceConfiguration.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/PeerConfiguration.swift
${WG_APPLE_SOURCE_DIR}/Shared/FileManager+Extension.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKitC/x25519.c
${WG_APPLE_SOURCE_DIR}/WireGuardKit/Array+ConcurrentMap.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/IPAddress+AddrInfo.swift
${WG_APPLE_SOURCE_DIR}/WireGuardKit/PrivateKey.swift
${CLIENT_ROOT_DIR}/platforms/ios/HevSocksTunnel.swift
${CLIENT_ROOT_DIR}/platforms/ios/NELogController.swift
${CLIENT_ROOT_DIR}/platforms/ios/Log.swift
${CLIENT_ROOT_DIR}/platforms/ios/LogRecord.swift
${CLIENT_ROOT_DIR}/platforms/ios/PacketTunnelProvider.swift
${CLIENT_ROOT_DIR}/platforms/ios/PacketTunnelProvider+WireGuard.swift
${CLIENT_ROOT_DIR}/platforms/ios/PacketTunnelProvider+OpenVPN.swift
${CLIENT_ROOT_DIR}/platforms/ios/PacketTunnelProvider+Xray.swift
${CLIENT_ROOT_DIR}/platforms/ios/WGConfig.swift
${CLIENT_ROOT_DIR}/platforms/ios/iosglue.mm
)
target_sources(networkextension PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/PrivacyInfo.xcprivacy
)
set_property(TARGET networkextension APPEND PROPERTY RESOURCE
${CMAKE_CURRENT_SOURCE_DIR}/PrivacyInfo.xcprivacy
)
## Build wireguard-go-version.h
execute_process(
COMMAND go list -m golang.zx2c4.com/wireguard
WORKING_DIRECTORY ${CLIENT_ROOT_DIR}/3rd/wireguard-apple/Sources/WireGuardKitGo
OUTPUT_VARIABLE WG_VERSION_FULL
)
string(REGEX REPLACE ".*v\([0-9.]*\).*" "\\1" WG_VERSION_STRING 1.1.1)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/wireguard-go-version.h.in
${CMAKE_CURRENT_BINARY_DIR}/wireguard-go-version.h)
target_sources(networkextension PRIVATE
${CMAKE_CURRENT_BINARY_DIR}/wireguard-go-version.h)
target_include_directories(networkextension PRIVATE ${CLIENT_ROOT_DIR})
target_include_directories(networkextension PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
target_link_libraries(networkextension PRIVATE ${CLIENT_ROOT_DIR}/3rd-prebuilt/3rd-prebuilt/wireguard/macos/x86_64/libwg-go.a)
# Print the root directory for debugging purposes
message("---------")
message(${CLIENT_ROOT_DIR})
message(${CLIENT_ROOT_DIR}/3rd-prebuilt/3rd-prebuilt/xray/HevSocks5Tunnel.xcframework/macos-arm64_x86_64/libhev-socks5-tunnel.a)
target_link_libraries("networkextension" PRIVATE "${CLIENT_ROOT_DIR}/3rd-prebuilt/3rd-prebuilt/xray/HevSocks5Tunnel.xcframework/macos-arm64_x86_64/libhev-socks5-tunnel.a")
target_include_directories(networkextension PRIVATE ${CLIENT_ROOT_DIR}/3rd-prebuilt/3rd-prebuilt/xray/HevSocks5Tunnel.xcframework/macos-arm64_x86_64/Headers)

View file

@ -3,27 +3,32 @@
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string> <string>en</string>
<key>CFBundleDisplayName</key>
<string>AmneziaVPNNetworkExtension</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string> <string>AmneziaVPNNetworkExtension</string>
<key>CFBundleIdentifier</key> <key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> <string>${BUILD_IOS_APP_IDENTIFIER}.network-extension</string>
<key>CFBundleInfoDictionaryVersion</key> <key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string> <string>6.0</string>
<key>CFBundleName</key> <key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string> <string>AmneziaVPNNetworkExtension</string>
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string> <string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string> <string>${APPLE_PROJECT_VERSION}</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string> <string>${CMAKE_PROJECT_VERSION_TWEAK}</string>
<key>ITSAppUsesNonExemptEncryption</key> <key>ITSAppUsesNonExemptEncryption</key>
<false/> <false/>
<key>LSMinimumSystemVersion</key> <key>LSMinimumSystemVersion</key>
<string>$(MACOSX_DEPLOYMENT_TARGET)</string> <string>${CMAKE_OSX_DEPLOYMENT_TARGET}</string>
<key>CFBundleDisplayName</key>
<string>AmneziaVPNNetworkExtension</string>
<key>NSExtension</key> <key>NSExtension</key>
<dict> <dict>
<key>NSExtensionPointIdentifier</key> <key>NSExtensionPointIdentifier</key>
@ -31,5 +36,11 @@
<key>NSExtensionPrincipalClass</key> <key>NSExtensionPrincipalClass</key>
<string>$(PRODUCT_MODULE_NAME).PacketTunnelProvider</string> <string>$(PRODUCT_MODULE_NAME).PacketTunnelProvider</string>
</dict> </dict>
<key>com.wireguard.ios.app_group_id</key>
<string>group.org.amnezia.AmneziaVPN</string>
<key>com.wireguard.macos.app_group_id</key>
<string>${BUILD_VPN_DEVELOPMENT_TEAM}.group.org.amnezia.AmneziaVPN</string>
</dict> </dict>
</plist> </plist>

View file

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>1C8F.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
</array>
</dict>
</plist>

View file

@ -1,10 +1,6 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "macos/gobridge/wireguard.h"
#include "wireguard-go-version.h" #include "wireguard-go-version.h"
#include "3rd/awg-apple/Sources/WireGuardKitC/WireGuardKitC.h" #include "3rd/amneziawg-apple/Sources/WireGuardKitGo/wireguard.h"
#include "3rd/amneziawg-apple/Sources/WireGuardKitC/WireGuardKitC.h"
#include <stdbool.h> #include <stdbool.h>
#include <stdint.h> #include <stdint.h>
@ -23,3 +19,8 @@ bool key_from_hex(uint8_t key[WG_KEY_LEN], const char* hex);
bool key_eq(const uint8_t key1[WG_KEY_LEN], const uint8_t key2[WG_KEY_LEN]); bool key_eq(const uint8_t key1[WG_KEY_LEN], const uint8_t key2[WG_KEY_LEN]);
void write_msg_to_log(const char* tag, const char* msg); void write_msg_to_log(const char* tag, const char* msg);
// Khai báo hàm C để Swift có thể sử dụng
void hev_socks5_tunnel_quit(void);
// Updated function definition in C
int hev_socks5_tunnel_main(const char* configFile, int fd);

View file

@ -0,0 +1,3 @@
#ifndef WIREGUARD_GO_VERSION
#define WIREGUARD_GO_VERSION "@WG_VERSION_STRING@"
#endif // WIREGUARD_GO_VERSION

View file

@ -0,0 +1,19 @@
#!/bin/sh
# go/clangwrap_macos.sh
# Lấy đường dẫn SDK cho macOS
SDK_PATH=`xcrun --sdk macosx --show-sdk-path`
# Tìm đường dẫn đến `clang` cho macOS
CLANG=`xcrun --sdk macosx --find clang`
# Xác định kiến trúc máy dựa trên biến GOARCH
if [ "$GOARCH" == "amd64" ]; then
CARCH="x86_64"
elif [ "$GOARCH" == "arm64" ]; then
CARCH="arm64"
fi
# Thực thi `clang` với các tùy chọn cụ thể cho macOS
exec $CLANG -arch $CARCH -isysroot $SDK_PATH -mmacosx-version-min=10.15 "$@"

View file

@ -0,0 +1,39 @@
#!/bin/bash
XCODEBUILD="/usr/bin/xcodebuild"
WORKINGDIR=`pwd`
PATCH="/usr/bin/patch"
echo "Building OpenVPNAdapter for macOS Network Extension (MacNE)..."
# Copy the Project-MacNE.xcconfig settings to amnezia.xcconfig
cat $WORKINGDIR/3rd/OpenVPNAdapter/Configuration/Project-MacNE.xcconfig > $WORKINGDIR/3rd/OpenVPNAdapter/Configuration/amnezia.xcconfig
# Append macOS-specific build directory configurations to amnezia.xcconfig
cat << EOF >> $WORKINGDIR/3rd/OpenVPNAdapter/Configuration/amnezia.xcconfig
PROJECT_TEMP_DIR = $WORKINGDIR/3rd/OpenVPNAdapter/build/OpenVPNAdapter.build
CONFIGURATION_BUILD_DIR = $WORKINGDIR/3rd/OpenVPNAdapter/build/Release-macos
BUILT_PRODUCTS_DIR = $WORKINGDIR/3rd/OpenVPNAdapter/build/Release-macos
EOF
# Exclude UIKit, include Cocoa for macOS
# echo "OTHER_LDFLAGS = -framework Cocoa" >> $WORKINGDIR/3rd/OpenVPNAdapter/Configuration/amnezia.xcconfig
# Fetch the current macOS SDK version dynamically
MACOSX_SDK=$(xcrun --sdk macosx --show-sdk-path | sed -E 's/.*MacOSX([0-9]+\.[0-9]+)\.sdk/\1/')
echo "Using macOS SDK version: $MACOSX_SDK"
cd 3rd/OpenVPNAdapter
# Build for macOS using the correct SDK and destination
if $XCODEBUILD -scheme OpenVPNAdapter -configuration Release -xcconfig Configuration/amnezia.xcconfig -sdk macosx$MACOSX_SDK -destination 'generic/platform=macOS' -project OpenVPNAdapter.xcodeproj ; then
echo "OpenVPNAdapter built successfully for macOS Network Extension (MacNE)"
else
echo "OpenVPNAdapter macOS Network Extension (MacNE) build failed..."
fi
# Remove CodeSignature if needed for macOS
rm -rf ./build/Release-macos/OpenVPNAdapter.framework/Versions/A/_CodeSignature
cd ../../

View file

@ -47,7 +47,7 @@ extension PacketTunnelProvider {
let configuration = OpenVPNConfiguration() let configuration = OpenVPNConfiguration()
configuration.fileContent = ovpnConfiguration configuration.fileContent = ovpnConfiguration
if str.contains("cloak") { if str.contains("cloak") {
configuration.setPTCloak() // configuration.setPTCloak()
} }
let evaluation: OpenVPNConfigurationEvaluation? let evaluation: OpenVPNConfigurationEvaluation?

View file

@ -1,10 +1,196 @@
//import Foundation
//import NetworkExtension
//import WireGuardKitGo
//
//enum XrayErrors: Error {
// case noXrayConfig
// case xrayConfigIsWrong
// case cantSaveXrayConfig
// case cantParseListenAndPort
// case cantSaveHevSocksConfig
//}
//
//extension Constants {
// static let cachesDirectory: URL = {
// if let cachesDirectoryURL = FileManager.default.urls(for: .cachesDirectory,
// in: .userDomainMask).first {
// return cachesDirectoryURL
// } else {
// fatalError("Unable to retrieve caches directory.")
// }
// }()
//}
//
//extension PacketTunnelProvider {
// func startXray(completionHandler: @escaping (Error?) -> Void) {
//
// // Xray configuration
// guard let protocolConfiguration = self.protocolConfiguration as? NETunnelProviderProtocol,
// let providerConfiguration = protocolConfiguration.providerConfiguration,
// let configData = providerConfiguration[Constants.xrayConfigKey] as? Data else {
// xrayLog(.error, message: "Can't get xray configuration")
// completionHandler(XrayErrors.noXrayConfig)
// return
// }
//
// // Tunnel settings
// let ipv6Enabled = false
// let hideVPNIcon = false
//
// let settings = NEPacketTunnelNetworkSettings(tunnelRemoteAddress: "254.1.1.1")
// settings.mtu = 9000
//
// settings.ipv4Settings = {
// let settings = NEIPv4Settings(addresses: ["198.18.0.1"], subnetMasks: ["255.255.0.0"])
// settings.includedRoutes = [NEIPv4Route.default()]
// return settings
// }()
//
// settings.ipv6Settings = {
// guard ipv6Enabled else {
// return nil
// }
// let settings = NEIPv6Settings(addresses: ["fd6e:a81b:704f:1211::1"], networkPrefixLengths: [64])
// settings.includedRoutes = [NEIPv6Route.default()]
// if hideVPNIcon {
// settings.excludedRoutes = [NEIPv6Route(destinationAddress: "::", networkPrefixLength: 128)]
// }
// return settings
// }()
//
// do {
// let xrayConfig = try JSONDecoder().decode(XrayConfig.self,
// from: configData)
//
// var dnsArray = [String]()
// if let dns1 = xrayConfig.dns1 {
// dnsArray.append(dns1)
// }
// if let dns2 = xrayConfig.dns2 {
// dnsArray.append(dns2)
// }
//
// settings.dnsSettings = !dnsArray.isEmpty
// ? NEDNSSettings(servers: dnsArray)
// : NEDNSSettings(servers: ["1.1.1.1"])
//
// let xrayConfigData = xrayConfig.config.data(using: .utf8)
//
// guard let xrayConfigData else {
// xrayLog(.error, message: "Can't encode config to data")
// completionHandler(XrayErrors.xrayConfigIsWrong)
// return
// }
//
// let jsonDict = try JSONSerialization.jsonObject(with: xrayConfigData,
// options: []) as? [String: Any]
//
// guard var jsonDict else {
// xrayLog(.error, message: "Can't parse address and port for hevSocks")
// completionHandler(XrayErrors.cantParseListenAndPort)
// return
// }
//
// let port = 10808
// let address = "::1"
//
// if var inboundsArray = jsonDict["inbounds"] as? [[String: Any]], !inboundsArray.isEmpty {
// inboundsArray[0]["port"] = port
// inboundsArray[0]["listen"] = address
// jsonDict["inbounds"] = inboundsArray
// }
//
// let updatedData = try JSONSerialization.data(withJSONObject: jsonDict, options: [])
//
// setTunnelNetworkSettings(settings) { [weak self] error in
// if let error {
// completionHandler(error)
// return
// }
//
// // Launch xray
// self?.setupAndStartXray(configData: updatedData) { xrayError in
// if let xrayError {
// completionHandler(xrayError)
// return
// }
//
// // Launch hevSocks
// self?.setupAndRunTun2socks(configData: updatedData,
// address: address,
// port: port,
// completionHandler: completionHandler)
// }
// }
// } catch {
// completionHandler(error)
// return
// }
// }
//
// func stopXray(completionHandler: () -> Void) {
// Socks5Tunnel.quit()
// LibXrayStopXray()
// completionHandler()
// }
//
// private func setupAndStartXray(configData: Data,
// completionHandler: @escaping (Error?) -> Void) {
// let path = Constants.cachesDirectory.appendingPathComponent("config.json", isDirectory: false).path
// guard FileManager.default.createFile(atPath: path, contents: configData) else {
// xrayLog(.error, message: "Can't save xray configuration")
// completionHandler(XrayErrors.cantSaveXrayConfig)
// return
// }
//
// LibXrayRunXray(nil,
// path,
// Int64.max)
//
// completionHandler(nil)
// xrayLog(.info, message: "Xray started")
// }
//
// private func setupAndRunTun2socks(configData: Data,
// address: String,
// port: Int,
// completionHandler: @escaping (Error?) -> Void) {
// let config = """
// tunnel:
// mtu: 9000
// socks5:
// port: \(port)
// address: \(address)
// udp: 'udp'
// misc:
// task-stack-size: 20480
// connect-timeout: 5000
// read-write-timeout: 60000
// log-file: stderr
// log-level: error
// limit-nofile: 65535
// """
//
// let configurationFilePath = Constants.cachesDirectory.appendingPathComponent("config.yml", isDirectory: false).path
// guard FileManager.default.createFile(atPath: configurationFilePath, contents: config.data(using: .utf8)!) else {
// xrayLog(.info, message: "Cant save hevSocks configuration")
// completionHandler(XrayErrors.cantSaveHevSocksConfig)
// return
// }
//
// DispatchQueue.global().async {
// xrayLog(.info, message: "Hev socks started")
// completionHandler(nil)
// Socks5Tunnel.run(withConfig: configurationFilePath)
// }
// }
//}
import Foundation import Foundation
import NetworkExtension import NetworkExtension
import WireGuardKitGo import WireGuardKitGo
enum XrayErrors: Error { enum XrayErrors: Error {
case noXrayConfig case noXrayConfig
case xrayConfigIsWrong
case cantSaveXrayConfig case cantSaveXrayConfig
case cantParseListenAndPort case cantParseListenAndPort
case cantSaveHevSocksConfig case cantSaveHevSocksConfig
@ -27,14 +213,14 @@ extension PacketTunnelProvider {
// Xray configuration // Xray configuration
guard let protocolConfiguration = self.protocolConfiguration as? NETunnelProviderProtocol, guard let protocolConfiguration = self.protocolConfiguration as? NETunnelProviderProtocol,
let providerConfiguration = protocolConfiguration.providerConfiguration, let providerConfiguration = protocolConfiguration.providerConfiguration,
let configData = providerConfiguration[Constants.xrayConfigKey] as? Data else { let xrayConfigData = providerConfiguration[Constants.xrayConfigKey] as? Data else {
xrayLog(.error, message: "Can't get xray configuration") xrayLog(.error, message: "Can't get xray configuration")
completionHandler(XrayErrors.noXrayConfig) completionHandler(XrayErrors.noXrayConfig)
return return
} }
// Tunnel settings // Tunnel settings
let ipv6Enabled = false let ipv6Enabled = true
let hideVPNIcon = false let hideVPNIcon = false
let settings = NEPacketTunnelNetworkSettings(tunnelRemoteAddress: "254.1.1.1") let settings = NEPacketTunnelNetworkSettings(tunnelRemoteAddress: "254.1.1.1")
@ -58,29 +244,12 @@ extension PacketTunnelProvider {
return settings return settings
}() }()
let dns = ["8.8.4.4","1.1.1.1"]
settings.dnsSettings = NEDNSSettings(servers: dns)
do { do {
let xrayConfig = try JSONDecoder().decode(XrayConfig.self, let port = 10808
from: configData) let address = "::1"
var dnsArray = [String]()
if let dns1 = xrayConfig.dns1 {
dnsArray.append(dns1)
}
if let dns2 = xrayConfig.dns2 {
dnsArray.append(dns2)
}
settings.dnsSettings = !dnsArray.isEmpty
? NEDNSSettings(servers: dnsArray)
: NEDNSSettings(servers: ["1.1.1.1"])
let xrayConfigData = xrayConfig.config.data(using: .utf8)
guard let xrayConfigData else {
xrayLog(.error, message: "Can't encode config to data")
completionHandler(XrayErrors.xrayConfigIsWrong)
return
}
let jsonDict = try JSONSerialization.jsonObject(with: xrayConfigData, let jsonDict = try JSONSerialization.jsonObject(with: xrayConfigData,
options: []) as? [String: Any] options: []) as? [String: Any]
@ -91,9 +260,6 @@ extension PacketTunnelProvider {
return return
} }
let port = 10808
let address = "::1"
if var inboundsArray = jsonDict["inbounds"] as? [[String: Any]], !inboundsArray.isEmpty { if var inboundsArray = jsonDict["inbounds"] as? [[String: Any]], !inboundsArray.isEmpty {
inboundsArray[0]["port"] = port inboundsArray[0]["port"] = port
inboundsArray[0]["listen"] = address inboundsArray[0]["listen"] = address

View file

@ -1,3 +1,4 @@
#if !MACOS_NE
#include "QRCodeReaderBase.h" #include "QRCodeReaderBase.h"
#import <UIKit/UIKit.h> #import <UIKit/UIKit.h>
@ -108,3 +109,19 @@ void QRCodeReader::startReading() {
void QRCodeReader::stopReading() { void QRCodeReader::stopReading() {
[m_qrCodeReader stopReading]; [m_qrCodeReader stopReading];
} }
#else
#include "QRCodeReaderBase.h"
QRCodeReader::QRCodeReader()
{
}
QRect QRCodeReader::cameraSize() {
return QRect();
}
void QRCodeReader::startReading() {}
void QRCodeReader::stopReading() {}
void QRCodeReader::setCameraSize(QRect) {}
#endif

View file

@ -1,5 +1,6 @@
#if !MACOS_NE
#import <UIKit/UIKit.h> #import <UIKit/UIKit.h>
#endif
@interface QIOSApplicationDelegate @interface QIOSApplicationDelegate
@end @end

View file

@ -5,7 +5,7 @@
@implementation QIOSApplicationDelegate (AmneziaVPNDelegate) @implementation QIOSApplicationDelegate (AmneziaVPNDelegate)
#if !MACOS_NE
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{ {
[application setMinimumBackgroundFetchInterval: UIApplicationBackgroundFetchIntervalMinimum]; [application setMinimumBackgroundFetchInterval: UIApplicationBackgroundFetchIntervalMinimum];
@ -57,5 +57,5 @@
} }
return NO; return NO;
} }
#endif
@end @end

View file

@ -1,3 +1,13 @@
#if MACOS_NE
public func toggleScreenshots(_ isEnabled: Bool) {
}
class ScreenProtection {
}
#else
import UIKit import UIKit
public func toggleScreenshots(_ isEnabled: Bool) { public func toggleScreenshots(_ isEnabled: Bool) {
@ -85,3 +95,4 @@ struct ProtectionPair {
textField.removeFromSuperview() textField.removeFromSuperview()
} }
} }
#endif

View file

@ -27,6 +27,7 @@ const char* MessageKey::isOnDemand = "is-on-demand";
const char* MessageKey::SplitTunnelType = "SplitTunnelType"; const char* MessageKey::SplitTunnelType = "SplitTunnelType";
const char* MessageKey::SplitTunnelSites = "SplitTunnelSites"; const char* MessageKey::SplitTunnelSites = "SplitTunnelSites";
#if !MACOS_NE
static UIViewController* getViewController() { static UIViewController* getViewController() {
NSArray *windows = [[UIApplication sharedApplication]windows]; NSArray *windows = [[UIApplication sharedApplication]windows];
for (UIWindow *window in windows) { for (UIWindow *window in windows) {
@ -36,6 +37,7 @@ static UIViewController* getViewController() {
} }
return nil; return nil;
} }
#endif
Vpn::ConnectionState iosStatusToState(NEVPNStatus status) { Vpn::ConnectionState iosStatusToState(NEVPNStatus status) {
switch (status) { switch (status) {
@ -789,14 +791,14 @@ bool IosController::shareText(const QStringList& filesToSend) {
NSURL *logFileUrl = [[NSURL alloc] initFileURLWithPath:filesToSend[i].toNSString()]; NSURL *logFileUrl = [[NSURL alloc] initFileURLWithPath:filesToSend[i].toNSString()];
[sharingItems addObject:logFileUrl]; [sharingItems addObject:logFileUrl];
} }
#if !MACOS_NE
UIViewController *qtController = getViewController(); UIViewController *qtController = getViewController();
if (!qtController) return; if (!qtController) return;
UIActivityViewController *activityController = [[UIActivityViewController alloc] initWithActivityItems:sharingItems applicationActivities:nil]; UIActivityViewController *activityController = [[UIActivityViewController alloc] initWithActivityItems:sharingItems applicationActivities:nil];
#endif
__block bool isAccepted = false; __block bool isAccepted = false;
#if !MACOS_NE
[activityController setCompletionWithItemsHandler:^(NSString *activityType, BOOL completed, NSArray *returnedItems, NSError *activityError) { [activityController setCompletionWithItemsHandler:^(NSString *activityType, BOOL completed, NSArray *returnedItems, NSError *activityError) {
isAccepted = completed; isAccepted = completed;
emit finished(); emit finished();
@ -808,7 +810,7 @@ bool IosController::shareText(const QStringList& filesToSend) {
popController.sourceView = qtController.view; popController.sourceView = qtController.view;
popController.sourceRect = CGRectMake(100, 100, 100, 100); popController.sourceRect = CGRectMake(100, 100, 100, 100);
} }
#endif
QEventLoop wait; QEventLoop wait;
QObject::connect(this, &IosController::finished, &wait, &QEventLoop::quit); QObject::connect(this, &IosController::finished, &wait, &QEventLoop::quit);
wait.exec(); wait.exec();
@ -817,6 +819,7 @@ bool IosController::shareText(const QStringList& filesToSend) {
} }
QString IosController::openFile() { QString IosController::openFile() {
#if !MACOS_NE
UIDocumentPickerViewController *documentPicker = [[UIDocumentPickerViewController alloc] initWithDocumentTypes:@[@"public.item"] inMode:UIDocumentPickerModeOpen]; UIDocumentPickerViewController *documentPicker = [[UIDocumentPickerViewController alloc] initWithDocumentTypes:@[@"public.item"] inMode:UIDocumentPickerModeOpen];
DocumentPickerDelegate *documentPickerDelegate = [[DocumentPickerDelegate alloc] init]; DocumentPickerDelegate *documentPickerDelegate = [[DocumentPickerDelegate alloc] init];
@ -826,9 +829,9 @@ QString IosController::openFile() {
if (!qtController) return; if (!qtController) return;
[qtController presentViewController:documentPicker animated:YES completion:nil]; [qtController presentViewController:documentPicker animated:YES completion:nil];
#endif
__block QString filePath; __block QString filePath;
#if !MACOS_NE
documentPickerDelegate.documentPickerClosedCallback = ^(NSString *path) { documentPickerDelegate.documentPickerClosedCallback = ^(NSString *path) {
if (path) { if (path) {
filePath = QString::fromUtf8(path.UTF8String); filePath = QString::fromUtf8(path.UTF8String);
@ -837,7 +840,7 @@ QString IosController::openFile() {
} }
emit finished(); emit finished();
}; };
#endif
QEventLoop wait; QEventLoop wait;
QObject::connect(this, &IosController::finished, &wait, &QEventLoop::quit); QObject::connect(this, &IosController::finished, &wait, &QEventLoop::quit);
wait.exec(); wait.exec();
@ -863,3 +866,4 @@ void IosController::requestInetAccess() {
}]; }];
[task resume]; [task resume];
} }

View file

@ -1,7 +1,11 @@
#import <NetworkExtension/NetworkExtension.h> #import <NetworkExtension/NetworkExtension.h>
#import <NetworkExtension/NETunnelProviderSession.h> #import <NetworkExtension/NETunnelProviderSession.h>
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#if !MACOS_NE
#include <UIKit/UIKit.h> #include <UIKit/UIKit.h>
#endif
#include <Security/Security.h> #include <Security/Security.h>
class IosController; class IosController;
@ -17,9 +21,10 @@ class IosController;
@end @end
typedef void (^DocumentPickerClosedCallback)(NSString *path); typedef void (^DocumentPickerClosedCallback)(NSString *path);
#if !MACOS_NE
@interface DocumentPickerDelegate : NSObject <UIDocumentPickerDelegate> @interface DocumentPickerDelegate : NSObject <UIDocumentPickerDelegate>
@property (nonatomic, copy) DocumentPickerClosedCallback documentPickerClosedCallback; @property (nonatomic, copy) DocumentPickerClosedCallback documentPickerClosedCallback;
@end @end
#endif

View file

@ -26,6 +26,7 @@
@end @end
#if !MACOS_NE
@implementation DocumentPickerDelegate @implementation DocumentPickerDelegate
- (void)documentPicker:(UIDocumentPickerViewController *)controller didPickDocumentsAtURLs:(NSArray<NSURL *> *)urls { - (void)documentPicker:(UIDocumentPickerViewController *)controller didPickDocumentsAtURLs:(NSArray<NSURL *> *)urls {
@ -43,3 +44,4 @@
} }
@end @end
#endif

View file

@ -6,6 +6,8 @@
#import <UserNotifications/UserNotifications.h> #import <UserNotifications/UserNotifications.h>
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#if !MACOS_NE
#import <UIKit/UIKit.h> #import <UIKit/UIKit.h>
@interface IOSNotificationDelegate @interface IOSNotificationDelegate
@ -87,3 +89,86 @@ void IOSNotificationHandler::notify(NotificationHandler::Message type, const QSt
} }
}]; }];
} }
#else
// Removed the UIResponder and UIApplicationDelegate references as these are not available in macOS
@interface IOSNotificationDelegate
: NSObject <UNUserNotificationCenterDelegate> {
IOSNotificationHandler* m_iosNotificationHandler;
}
@end
@implementation IOSNotificationDelegate
- (id)initWithObject:(IOSNotificationHandler*)notification {
self = [super init]; // Removed `super init` as it refers to UIResponder, which is iOS specific
if (self) {
m_iosNotificationHandler = notification;
}
return self;
}
- (void)userNotificationCenter:(UNUserNotificationCenter*)center
willPresentNotification:(UNNotification*)notification
withCompletionHandler:
(void (^)(UNNotificationPresentationOptions options))completionHandler {
Q_UNUSED(center)
completionHandler(UNNotificationPresentationOptionList | UNNotificationPresentationOptionBanner);
}
- (void)userNotificationCenter:(UNUserNotificationCenter*)center
didReceiveNotificationResponse:(UNNotificationResponse*)response
withCompletionHandler:(void (^)())completionHandler {
Q_UNUSED(center)
Q_UNUSED(response)
completionHandler();
}
@end
IOSNotificationHandler::IOSNotificationHandler(QObject* parent) : NotificationHandler(parent) {
UNUserNotificationCenter* center = [UNUserNotificationCenter currentNotificationCenter];
[center requestAuthorizationWithOptions:(UNAuthorizationOptionSound | UNAuthorizationOptionAlert |
UNAuthorizationOptionBadge)
completionHandler:^(BOOL granted, NSError* _Nullable error) {
Q_UNUSED(granted);
if (!error) {
m_delegate = [[IOSNotificationDelegate alloc] initWithObject:this];
}
}];
}
IOSNotificationHandler::~IOSNotificationHandler() { }
void IOSNotificationHandler::notify(NotificationHandler::Message type, const QString& title,
const QString& message, int timerMsec) {
Q_UNUSED(type);
if (!m_delegate) {
return;
}
UNMutableNotificationContent* content = [[UNMutableNotificationContent alloc] init];
content.title = title.toNSString();
content.body = message.toNSString();
content.sound = [UNNotificationSound defaultSound];
int timerSec = timerMsec / 1000;
UNTimeIntervalNotificationTrigger* trigger =
[UNTimeIntervalNotificationTrigger triggerWithTimeInterval:timerSec repeats:NO];
UNNotificationRequest* request = [UNNotificationRequest requestWithIdentifier:@"amneziavpn"
content:content
trigger:trigger];
UNUserNotificationCenter* center = [UNUserNotificationCenter currentNotificationCenter];
center.delegate = (id<UNUserNotificationCenterDelegate>)m_delegate;
[center addNotificationRequest:request
withCompletionHandler:^(NSError* _Nullable error) {
if (error) {
NSLog(@"Local Notification failed");
}
}];
}
#endif

View file

@ -4,7 +4,7 @@
#include "core/errorstrings.h" #include "core/errorstrings.h"
#include "vpnprotocol.h" #include "vpnprotocol.h"
#if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) #if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) and !defined MACOS_NE || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID))
#include "openvpnovercloakprotocol.h" #include "openvpnovercloakprotocol.h"
#include "openvpnprotocol.h" #include "openvpnprotocol.h"
#include "shadowsocksvpnprotocol.h" #include "shadowsocksvpnprotocol.h"
@ -109,7 +109,7 @@ VpnProtocol *VpnProtocol::factory(DockerContainer container, const QJsonObject &
#if defined(Q_OS_WINDOWS) #if defined(Q_OS_WINDOWS)
case DockerContainer::Ipsec: return new Ikev2Protocol(configuration); case DockerContainer::Ipsec: return new Ikev2Protocol(configuration);
#endif #endif
#if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) #if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) and !defined MACOS_NE || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID))
case DockerContainer::OpenVpn: return new OpenVpnProtocol(configuration); case DockerContainer::OpenVpn: return new OpenVpnProtocol(configuration);
case DockerContainer::Cloak: return new OpenVpnOverCloakProtocol(configuration); case DockerContainer::Cloak: return new OpenVpnOverCloakProtocol(configuration);
case DockerContainer::ShadowSocks: return new ShadowSocksVpnProtocol(configuration); case DockerContainer::ShadowSocks: return new ShadowSocksVpnProtocol(configuration);

View file

@ -258,18 +258,18 @@ Can&apos;t be disabled for current server</source>
<translation>غير قادر علي فتح الملف</translation> <translation>غير قادر علي فتح الملف</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>ملف تكوين غير صحيح</translation> <translation>ملف تكوين غير صحيح</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>تم فحص%1 من %2.</translation> <translation>تم فحص%1 من %2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation>في التكوين المستورد، تم العثور على سطور يحتمل أن تكون خطرة:</translation> <translation>في التكوين المستورد، تم العثور على سطور يحتمل أن تكون خطرة:</translation>
</message> </message>
@ -401,28 +401,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>تم الاتصال</translation> <translation>تم الاتصال</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>تم إنهاء الاتصال</translation> <translation>تم إنهاء الاتصال</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>إشعار من AmneziaVPN</translation> <translation>إشعار من AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>تم العثور علي شبكة غير مؤمنة: </translation> <translation>تم العثور علي شبكة غير مؤمنة: </translation>
</message> </message>
@ -2426,12 +2426,12 @@ Already installed containers were found on the server. All installed containers
<translation>عنوان خادم IP [:منفذ]</translation> <translation>عنوان خادم IP [:منفذ]</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>واصل</translation> <translation>واصل</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>ستظل جميع البيانات التي تدخلها سرية للغاية ولن تتم مشاركتها أو الكشف عنها ل Amnezia أو أي طرف ثالث</translation> <translation>ستظل جميع البيانات التي تدخلها سرية للغاية ولن تتم مشاركتها أو الكشف عنها ل Amnezia أو أي طرف ثالث</translation>
</message> </message>
@ -2441,42 +2441,42 @@ Already installed containers were found on the server. All installed containers
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>كلمة مرور او مفتاح SSH خاص</translation> <translation>كلمة مرور او مفتاح SSH خاص</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation>كيف تقوم بتشغيل خادم ال VPN الخاص بك</translation> <translation>كيف تقوم بتشغيل خادم ال VPN الخاص بك</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation>اين تحصل علي بيانات الاتصال, تعليمات خطوة ب خطوة لشراء VPS</translation> <translation>اين تحصل علي بيانات الاتصال, تعليمات خطوة ب خطوة لشراء VPS</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>لا يمكن لعنوان IP ان يكون فارغ</translation> <translation>لا يمكن لعنوان IP ان يكون فارغ</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>ادخل العنوان في شكل 255.255.255.255:88</translation> <translation>ادخل العنوان في شكل 255.255.255.255:88</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>تسجيل دخول لا يمكن ان يكون فارغ</translation> <translation>تسجيل دخول لا يمكن ان يكون فارغ</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>كلمة مرور/مفتاح خاص لأ يمكن ان يكونو فارغين</translation> <translation>كلمة مرور/مفتاح خاص لأ يمكن ان يكونو فارغين</translation>
</message> </message>
@ -2791,42 +2791,47 @@ Already installed containers were found on the server. All installed containers
<translation>البيانات المٌرسلة: %1</translation> <translation>البيانات المٌرسلة: %1</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation>إعادة التسمية</translation> <translation>إعادة التسمية</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>اسم العميل</translation> <translation>اسم العميل</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation>احفظ</translation> <translation>احفظ</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>سحب وإبطال</translation> <translation>سحب وإبطال</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>سحب وإبطال للمستخدم - %1?</translation> <translation>سحب وإبطال للمستخدم - %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>المستخدم لن يكون قادر علي الاتصال بعد الان.</translation> <translation>المستخدم لن يكون قادر علي الاتصال بعد الان.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>واصل</translation> <translation>واصل</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>إلغاء</translation> <translation>إلغاء</translation>
</message> </message>
@ -4100,12 +4105,12 @@ While it offers a blend of security, stability, and speed, it&apos;s essential t
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>عبارة المرور الخاصة بالمفتاح</translation> <translation>عبارة المرور الخاصة بالمفتاح</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation>احفظ</translation> <translation>احفظ</translation>
</message> </message>

View file

@ -263,18 +263,18 @@ Can&apos;t be disabled for current server</source>
<translation>نمیتوان فایل را باز کرد.</translation> <translation>نمیتوان فایل را باز کرد.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>فایل پیکربندی نامعتبر است.</translation> <translation>فایل پیکربندی نامعتبر است.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>ارزیابی %1 از %2.</translation> <translation>ارزیابی %1 از %2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation>در پیکربندی وارد شده، خطوطی که ممکن است خطرناک باشند، یافت شدند:</translation> <translation>در پیکربندی وارد شده، خطوطی که ممکن است خطرناک باشند، یافت شدند:</translation>
</message> </message>
@ -405,28 +405,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>ویپیان وصل شد</translation> <translation>ویپیان وصل شد</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>ویپیان قطع شد</translation> <translation>ویپیان قطع شد</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>اخطار AmneziaVPN</translation> <translation>اخطار AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>شبکه ناامن شناسایی شد: </translation> <translation>شبکه ناامن شناسایی شد: </translation>
</message> </message>
@ -2544,12 +2544,12 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<translation>آدرس آیپی سرور (:پورت)</translation> <translation>آدرس آیپی سرور (:پورت)</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>ادامه</translation> <translation>ادامه</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>آدرس را با فرمت 255.255.255.255:88 وارد کنید</translation> <translation>آدرس را با فرمت 255.255.255.255:88 وارد کنید</translation>
</message> </message>
@ -2564,42 +2564,42 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>رمز عبور یا کلید خصوصی SSH</translation> <translation>رمز عبور یا کلید خصوصی SSH</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>تمام دادههایی که شما وارد میکنید به شدت محرمانه است و با Amnezia یا هر شخص ثالث دیگری به اشتراک گذاشته نمیشود</translation> <translation>تمام دادههایی که شما وارد میکنید به شدت محرمانه است و با Amnezia یا هر شخص ثالث دیگری به اشتراک گذاشته نمیشود</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation>چگونه سرور VPN خود را اجرا کنید</translation> <translation>چگونه سرور VPN خود را اجرا کنید</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation>دادههای اتصال را از کجا دریافت کنید و دستورالعملهای مرحله به مرحله برای خرید یک VPS</translation> <translation>دادههای اتصال را از کجا دریافت کنید و دستورالعملهای مرحله به مرحله برای خرید یک VPS</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>آدرس آیپی نمیتواند خالی باشد</translation> <translation>آدرس آیپی نمیتواند خالی باشد</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>نامکاربری نمیتواند خالی باشد</translation> <translation>نامکاربری نمیتواند خالی باشد</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>پسورد یا کلید خصوصی نمیتواند خالی باشد</translation> <translation>پسورد یا کلید خصوصی نمیتواند خالی باشد</translation>
</message> </message>
@ -2958,47 +2958,52 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation>دادههای ارسال شده: %1</translation> <translation>دادههای ارسال شده: %1</translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="vanished">تاریخ ایجاد: </translation> <translation type="vanished">تاریخ ایجاد: </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation>تغییر نام</translation> <translation>تغییر نام</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>نام کلاینت</translation> <translation>نام کلاینت</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation>ذخیره</translation> <translation>ذخیره</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>ابطال</translation> <translation>ابطال</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>لغو پیکربندی برای یک کاربر - %1?</translation> <translation>لغو پیکربندی برای یک کاربر - %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>کاربر دیگر نمیتواند به سرور وصل شود.</translation> <translation>کاربر دیگر نمیتواند به سرور وصل شود.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>ادامه</translation> <translation>ادامه</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>کنسل</translation> <translation>کنسل</translation>
</message> </message>
@ -4316,12 +4321,12 @@ For more detailed information, you can
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>عبارت کلید خصوصی</translation> <translation>عبارت کلید خصوصی</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation>ذخیره</translation> <translation>ذخیره</translation>
</message> </message>

View file

@ -259,18 +259,18 @@ Can&apos;t be disabled for current server</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation> ि </translation> <translation> ि </translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>%2 %1 ि .</translation> <translation>%2 %1 ि .</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
@ -401,28 +401,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>AmneziaVPN ि</translation> <translation>AmneziaVPN ि</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>ि : </translation> <translation>ि : </translation>
</message> </message>
@ -2494,12 +2494,12 @@ Already installed containers were found on the server. All installed containers
<translation> [:]</translation> <translation> [:]</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation> ि ि ि ि </translation> <translation> ि ि ि ि </translation>
</message> </message>
@ -2509,42 +2509,42 @@ Already installed containers were found on the server. All installed containers
<translation>255.255.255.255:22</translation> <translation>255.255.255.255:22</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>SSH </translation> <translation>SSH </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation> SSH ि </translation> <translation> SSH ि </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation> 255.255.255.255:88 </translation> <translation> 255.255.255.255:88 </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>ि </translation> <translation>ि </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>/ि </translation> <translation>/ि </translation>
</message> </message>
@ -2876,47 +2876,52 @@ Already installed containers were found on the server. All installed containers
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation> : %1</translation> <translation> : %1</translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="vanished">ि िि: </translation> <translation type="vanished">ि िि: </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>ि </translation> <translation>ि </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>ि ि ि ि - %1?</translation> <translation>ि ि ि ि - %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation> .</translation> <translation> .</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation> </translation> <translation> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation> </translation> <translation> </translation>
</message> </message>
@ -4208,12 +4213,12 @@ While it offers a blend of security, stability, and speed, it&apos;s essential t
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>ि </translation> <translation>ि </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>

View file

@ -259,18 +259,18 @@ Can&apos;t be disabled for current server</source>
<translation>က</translation> <translation>က</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>Configuration က</translation> <translation>Configuration က</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>%2 %1 က က.</translation> <translation>%2 %1 က က.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation> configuration က :</translation> <translation> configuration က :</translation>
</message> </message>
@ -401,28 +401,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>VPN က</translation> <translation>VPN က</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>VPN က</translation> <translation>VPN က</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>AmneziaVPN </translation> <translation>AmneziaVPN </translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>ကက က: </translation> <translation>ကက က: </translation>
</message> </message>
@ -2430,12 +2430,12 @@ Already installed containers were found on the server. All installed containers
<translation> IP [:port]</translation> <translation> IP [:port]</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>ကက</translation> <translation>ကက</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>က 255.255.255.255:88 </translation> <translation>က 255.255.255.255:88 </translation>
</message> </message>
@ -2450,42 +2450,42 @@ Already installed containers were found on the server. All installed containers
<translation>255.255.255.255:22</translation> <translation>255.255.255.255:22</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>SSH </translation> <translation>SSH </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>ကက SSH private key</translation> <translation>ကက SSH private key</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>က ကက Amnezia က </translation> <translation>က ကက Amnezia က </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation>က </translation> <translation>က </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation>ကက VPS က ကက</translation> <translation>ကက VPS က ကက</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>IP </translation> <translation>IP </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>ကက </translation> <translation>ကက </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>ကက/private key </translation> <translation>ကက/private key </translation>
</message> </message>
@ -2825,42 +2825,47 @@ Already installed containers were found on the server. All installed containers
<translation>က: %1</translation> <translation>က: %1</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>က</translation> <translation>က</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation> %1 က config က ?</translation> <translation> %1 က config က ?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation> က.</translation> <translation> က.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>ကက</translation> <translation>ကက</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>က</translation> <translation>က</translation>
</message> </message>
@ -4105,12 +4110,12 @@ For more detailed information, you can
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>က key ကက</translation> <translation>က key ကက</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>

View file

@ -263,18 +263,18 @@ Can&apos;t be disabled for current server</source>
<translation>Невозможно открыть файл</translation> <translation>Невозможно открыть файл</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>Неверный файл конфигурации</translation> <translation>Неверный файл конфигурации</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>Отсканировано %1 из %2.</translation> <translation>Отсканировано %1 из %2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation>В импортированной конфигурации были обнаружены потенциально опасные строки:</translation> <translation>В импортированной конфигурации были обнаружены потенциально опасные строки:</translation>
</message> </message>
@ -405,28 +405,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>VPN подключен</translation> <translation>VPN подключен</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>VPN выключен</translation> <translation>VPN выключен</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>Уведомление AmneziaVPN</translation> <translation>Уведомление AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>Обнаружена незащищенная сеть: </translation> <translation>Обнаружена незащищенная сеть: </translation>
</message> </message>
@ -2628,7 +2628,7 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<translation type="vanished">Password / SSH private key</translation> <translation type="vanished">Password / SSH private key</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>Продолжить</translation> <translation>Продолжить</translation>
</message> </message>
@ -2638,7 +2638,7 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation type="vanished">Все данные, которые вы вводите, останутся строго конфиденциальными и не будут переданы или раскрыты Amnezia или каким-либо третьим лицам</translation> <translation type="vanished">Все данные, которые вы вводите, останутся строго конфиденциальными и не будут переданы или раскрыты Amnezia или каким-либо третьим лицам</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>Введите адрес в формате 255.255.255.255:88</translation> <translation>Введите адрес в формате 255.255.255.255:88</translation>
</message> </message>
@ -2657,42 +2657,42 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>255.255.255.255:22</translation> <translation>255.255.255.255:22</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>Имя пользователя SSH</translation> <translation>Имя пользователя SSH</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>Пароль или закрытый ключ SSH</translation> <translation>Пароль или закрытый ключ SSH</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>Все данные, которые вы вводите, останутся строго конфиденциальными и не будут переданы или раскрыты Amnezia или каким-либо третьим лицам</translation> <translation>Все данные, которые вы вводите, останутся строго конфиденциальными и не будут переданы или раскрыты Amnezia или каким-либо третьим лицам</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation>Как создать VPN на собственном сервере</translation> <translation>Как создать VPN на собственном сервере</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation>Где взять данные для подключения, пошаговые инстуркции по покупке VPS</translation> <translation>Где взять данные для подключения, пошаговые инстуркции по покупке VPS</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>Поле с IP-адресом не может быть пустым</translation> <translation>Поле с IP-адресом не может быть пустым</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>Поле с логином не может быть пустым</translation> <translation>Поле с логином не может быть пустым</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>Поле с паролем/закрытым ключом не может быть пустым</translation> <translation>Поле с паролем/закрытым ключом не может быть пустым</translation>
</message> </message>
@ -3087,47 +3087,52 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation>Отправлено данных: %1</translation> <translation>Отправлено данных: %1</translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="vanished">Дата создания: </translation> <translation type="vanished">Дата создания: </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation>Переименовать</translation> <translation>Переименовать</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>Имя клиента</translation> <translation>Имя клиента</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation>Сохранить</translation> <translation>Сохранить</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>Отозвать</translation> <translation>Отозвать</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>Отозвать конфигурацию для пользователя - %1?</translation> <translation>Отозвать конфигурацию для пользователя - %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>Пользователь больше не сможет подключаться к вашему серверу.</translation> <translation>Пользователь больше не сможет подключаться к вашему серверу.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>Продолжить</translation> <translation>Продолжить</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>Отменить</translation> <translation>Отменить</translation>
</message> </message>
@ -4547,12 +4552,12 @@ This means that AmneziaWG keeps the fast performance of the original while addin
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>Парольная фраза для закрытого ключа</translation> <translation>Парольная фраза для закрытого ключа</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation>Сохранить</translation> <translation>Сохранить</translation>
</message> </message>

View file

@ -290,18 +290,18 @@ Can&apos;t be disabled for current server</source>
<translation>Неможливо відкрити файл</translation> <translation>Неможливо відкрити файл</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>Недійсний файл конфігурації</translation> <translation>Недійсний файл конфігурації</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>Відскановано %1 з %2.</translation> <translation>Відскановано %1 з %2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation>У імпортованій конфігурації знайдено потенційно небезпечні рядки:</translation> <translation>У імпортованій конфігурації знайдено потенційно небезпечні рядки:</translation>
</message> </message>
@ -431,28 +431,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>AmneziaVPN</translation> <translation>AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>VPN Підключено</translation> <translation>VPN Підключено</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>VPN Вимкнено</translation> <translation>VPN Вимкнено</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>Сповіщення AmneziaVPN</translation> <translation>Сповіщення AmneziaVPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>Знайдена не захищена мережа: </translation> <translation>Знайдена не захищена мережа: </translation>
</message> </message>
@ -2714,7 +2714,7 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<translation type="vanished">Password / SSH private key</translation> <translation type="vanished">Password / SSH private key</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>Продовжити</translation> <translation>Продовжити</translation>
</message> </message>
@ -2725,7 +2725,7 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
і не будуть передані чи розголошені Amnezia або будь-яким третім особам</translation> і не будуть передані чи розголошені Amnezia або будь-яким третім особам</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>Введіть адресу в форматі 255.255.255.255:88</translation> <translation>Введіть адресу в форматі 255.255.255.255:88</translation>
</message> </message>
@ -2744,42 +2744,42 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>255.255.255.255:22</translation> <translation>255.255.255.255:22</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>SSH Username</translation> <translation>SSH Username</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>Пароль або SSH ключ</translation> <translation>Пароль або SSH ключ</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>Усі дані, які ви вводите, залишатимуться суворо конфіденційними та не будуть передані чи розголошені Amnezia або будь-яким третім особам</translation> <translation>Усі дані, які ви вводите, залишатимуться суворо конфіденційними та не будуть передані чи розголошені Amnezia або будь-яким третім особам</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation>Як запустити ваш VPN-сервер</translation> <translation>Як запустити ваш VPN-сервер</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation>Де отримати дані для підключення: покрокові інструкції з придбання VPS</translation> <translation>Де отримати дані для підключення: покрокові інструкції з придбання VPS</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>Поле IP address не може бути пустим</translation> <translation>Поле IP address не може бути пустим</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>Поле Login не може бути пустим</translation> <translation>Поле Login не може бути пустим</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>Поле Password/Private key не може бути пустим</translation> <translation>Поле Password/Private key не може бути пустим</translation>
</message> </message>
@ -3182,47 +3182,52 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation>Відправлено даних: %1</translation> <translation>Відправлено даних: %1</translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="obsolete">Дата створення:</translation> <translation type="obsolete">Дата створення:</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation>Перейменувати</translation> <translation>Перейменувати</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>Назва клієнта</translation> <translation>Назва клієнта</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation>Зберегти</translation> <translation>Зберегти</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>Відкликати</translation> <translation>Відкликати</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>Відкликати доступ для користувача - %1?</translation> <translation>Відкликати доступ для користувача - %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>Користувач більше не зможе підключатись до вашого сервера </translation> <translation>Користувач більше не зможе підключатись до вашого сервера </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>Продовжити</translation> <translation>Продовжити</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>Відмінити</translation> <translation>Відмінити</translation>
</message> </message>
@ -4624,12 +4629,12 @@ This means that AmneziaWG keeps the fast performance of the original while addin
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>Пароль для особистого ключа</translation> <translation>Пароль для особистого ключа</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation>Зберегти</translation> <translation>Зберегти</translation>
</message> </message>

View file

@ -257,18 +257,18 @@ Can&apos;t be disabled for current server</source>
<translation>فائل کو کھولنے سے قاصر ہے</translation> <translation>فائل کو کھولنے سے قاصر ہے</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation>غلط کنفیگریشن فائل</translation> <translation>غلط کنفیگریشن فائل</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation>سکین%1 کی%2.</translation> <translation>سکین%1 کی%2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
@ -399,30 +399,30 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation>The translation of &quot;AmneziaVPN&quot; in Urdu would be: <translation>The translation of &quot;AmneziaVPN&quot; in Urdu would be:
امنیزیا وی پی ای</translation> امنیزیا وی پی ای</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>وی پی این متصل ہوگیا</translation> <translation>وی پی این متصل ہوگیا</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>وی پی این منقطع ہوگیا</translation> <translation>وی پی این منقطع ہوگیا</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>امنیزیا وی پی این کی اطلاعات</translation> <translation>امنیزیا وی پی این کی اطلاعات</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation>غیر محفوظ نیٹ ورک کا پتہ لگایا گیا ہے: </translation> <translation>غیر محفوظ نیٹ ورک کا پتہ لگایا گیا ہے: </translation>
</message> </message>
@ -2498,12 +2498,12 @@ Already installed containers were found on the server. All installed containers
<translation>سرور آئی پی پتہ [:پورٹ]</translation> <translation>سرور آئی پی پتہ [:پورٹ]</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation>براہ کرم جاری رکھیں</translation> <translation>براہ کرم جاری رکھیں</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation>آپ جو ڈیٹا داخل کریں گے وہ بالکل خفیہ رہے گا اور نہ تو امنیزیا یا کسی تیسری شخصیت کے ساتھ اشتراک کیا جائے گا</translation> <translation>آپ جو ڈیٹا داخل کریں گے وہ بالکل خفیہ رہے گا اور نہ تو امنیزیا یا کسی تیسری شخصیت کے ساتھ اشتراک کیا جائے گا</translation>
</message> </message>
@ -2513,42 +2513,42 @@ Already installed containers were found on the server. All installed containers
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>ایس ایس ایچ صارف نام</translation> <translation>ایس ایس ایچ صارف نام</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation>پاس ورڈ یا SSH نجی کلید</translation> <translation>پاس ورڈ یا SSH نجی کلید</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>آئی پی پتہ خالی نہیں ہو سکتا</translation> <translation>آئی پی پتہ خالی نہیں ہو سکتا</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation>ایڈریس درج کریں فارمیٹ 255.255.255.255:88</translation> <translation>ایڈریس درج کریں فارمیٹ 255.255.255.255:88</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation>لاگ ان نام خالی نہیں ہو سکتا</translation> <translation>لاگ ان نام خالی نہیں ہو سکتا</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation>پاس ورڈ یا نجی کلید خالی نہیں ہو سکتی</translation> <translation>پاس ورڈ یا نجی کلید خالی نہیں ہو سکتی</translation>
</message> </message>
@ -2880,47 +2880,52 @@ Already installed containers were found on the server. All installed containers
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="vanished">تخلیق کی تاریخ: </translation> <translation type="vanished">تخلیق کی تاریخ: </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation>نام تبدیل</translation> <translation>نام تبدیل</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation>کلائنٹ کا نام</translation> <translation>کلائنٹ کا نام</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation>محفوظ</translation> <translation>محفوظ</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation>واپس لین</translation> <translation>واپس لین</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>کیا آپ مستعمل کے لئے کنفیگ کو واپس لینا چاہتے ہیں - %1؟</translation> <translation>کیا آپ مستعمل کے لئے کنفیگ کو واپس لینا چاہتے ہیں - %1؟</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>صارف آپ کے سرور سے متصل ہونے کا اختیار نہیں رہے گا.</translation> <translation>صارف آپ کے سرور سے متصل ہونے کا اختیار نہیں رہے گا.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation>جاری رکھیں</translation> <translation>جاری رکھیں</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation>منسوخ</translation> <translation>منسوخ</translation>
</message> </message>
@ -4154,12 +4159,12 @@ While it offers a blend of security, stability, and speed, it&apos;s essential t
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation>نجی کلید پاس فریز</translation> <translation>نجی کلید پاس فریز</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation>محفوظ کریں</translation> <translation>محفوظ کریں</translation>
</message> </message>

View file

@ -262,18 +262,18 @@ Can&apos;t be disabled for current server</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="187"/> <location filename="../ui/controllers/importController.cpp" line="191"/>
<location filename="../ui/controllers/importController.cpp" line="192"/> <location filename="../ui/controllers/importController.cpp" line="196"/>
<source>Invalid configuration file</source> <source>Invalid configuration file</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="617"/> <location filename="../ui/controllers/importController.cpp" line="622"/>
<source>Scanned %1 of %2.</source> <source>Scanned %1 of %2.</source>
<translation> %1 of %2.</translation> <translation> %1 of %2.</translation>
</message> </message>
<message> <message>
<location filename="../ui/controllers/importController.cpp" line="652"/> <location filename="../ui/controllers/importController.cpp" line="657"/>
<source>In the imported configuration, potentially dangerous lines were found:</source> <source>In the imported configuration, potentially dangerous lines were found:</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
@ -427,28 +427,28 @@ Already installed containers were found on the server. All installed containers
<context> <context>
<name>NotificationHandler</name> <name>NotificationHandler</name>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="63"/> <location filename="../ui/notificationhandler.cpp" line="66"/>
<location filename="../ui/notificationhandler.cpp" line="70"/> <location filename="../ui/notificationhandler.cpp" line="73"/>
<source>AmneziaVPN</source> <source>AmneziaVPN</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="64"/> <location filename="../ui/notificationhandler.cpp" line="67"/>
<source>VPN Connected</source> <source>VPN Connected</source>
<translation>VPN</translation> <translation>VPN</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="71"/> <location filename="../ui/notificationhandler.cpp" line="74"/>
<source>VPN Disconnected</source> <source>VPN Disconnected</source>
<translation>VPN断开</translation> <translation>VPN断开</translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="94"/> <location filename="../ui/notificationhandler.cpp" line="97"/>
<source>AmneziaVPN notification</source> <source>AmneziaVPN notification</source>
<translation>AmneziaVPN </translation> <translation>AmneziaVPN </translation>
</message> </message>
<message> <message>
<location filename="../ui/notificationhandler.cpp" line="95"/> <location filename="../ui/notificationhandler.cpp" line="98"/>
<source>Unsecured network detected: </source> <source>Unsecured network detected: </source>
<translation></translation> <translation></translation>
</message> </message>
@ -2673,12 +2673,12 @@ It&apos;s okay as long as it&apos;s from someone you trust.</source>
<translation type="vanished"> </translation> <translation type="vanished"> </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="116"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="113"/>
<source>Continue</source> <source>Continue</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="144"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="141"/>
<source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source> <source>All data you enter will remain strictly confidential and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation> Amnezia </translation> <translation> Amnezia </translation>
</message> </message>
@ -2694,42 +2694,42 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="78"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="75"/>
<source>SSH Username</source> <source>SSH Username</source>
<translation>SSH </translation> <translation>SSH </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="94"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="91"/>
<source>Password or SSH private key</source> <source>Password or SSH private key</source>
<translation> SSH </translation> <translation> SSH </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="153"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="150"/>
<source>How to run your VPN server</source> <source>How to run your VPN server</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="154"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="151"/>
<source>Where to get connection data, step-by-step instructions for buying a VPS</source> <source>Where to get connection data, step-by-step instructions for buying a VPS</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="167"/>
<source>Ip address cannot be empty</source> <source>Ip address cannot be empty</source>
<translation>IP不能为空</translation> <translation>IP不能为空</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="173"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="170"/>
<source>Enter the address in the format 255.255.255.255:88</source> <source>Enter the address in the format 255.255.255.255:88</source>
<translation> 255.255.255.255:88</translation> <translation> 255.255.255.255:88</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="177"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="174"/>
<source>Login cannot be empty</source> <source>Login cannot be empty</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="181"/> <location filename="../ui/qml/Pages2/PageSetupWizardCredentials.qml" line="178"/>
<source>Password/private key cannot be empty</source> <source>Password/private key cannot be empty</source>
<translation></translation> <translation></translation>
</message> </message>
@ -3086,47 +3086,52 @@ and will not be shared or disclosed to the Amnezia or any third parties</source>
<source>Data sent: %1</source> <source>Data sent: %1</source>
<translation type="unfinished"></translation> <translation type="unfinished"></translation>
</message> </message>
<message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="849"/>
<source>Allowed IPs: %1</source>
<translation type="unfinished"></translation>
</message>
<message> <message>
<source>Creation date: </source> <source>Creation date: </source>
<translation type="vanished">: </translation> <translation type="vanished">: </translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="862"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="870"/>
<source>Rename</source> <source>Rename</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="908"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="916"/>
<source>Client name</source> <source>Client name</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="921"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="929"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="955"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="963"/>
<source>Revoke</source> <source>Revoke</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="959"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="967"/>
<source>Revoke the config for a user - %1?</source> <source>Revoke the config for a user - %1?</source>
<translation>- %1?</translation> <translation>- %1?</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="960"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="968"/>
<source>The user will no longer be able to connect to your server.</source> <source>The user will no longer be able to connect to your server.</source>
<translation>.</translation> <translation>.</translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="961"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="969"/>
<source>Continue</source> <source>Continue</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/Pages2/PageShare.qml" line="962"/> <location filename="../ui/qml/Pages2/PageShare.qml" line="970"/>
<source>Cancel</source> <source>Cancel</source>
<translation></translation> <translation></translation>
</message> </message>
@ -4610,12 +4615,12 @@ While it offers a blend of security, stability, and speed, it&apos;s essential t
<context> <context>
<name>main2</name> <name>main2</name>
<message> <message>
<location filename="../ui/qml/main2.qml" line="162"/> <location filename="../ui/qml/main2.qml" line="163"/>
<source>Private key passphrase</source> <source>Private key passphrase</source>
<translation></translation> <translation></translation>
</message> </message>
<message> <message>
<location filename="../ui/qml/main2.qml" line="185"/> <location filename="../ui/qml/main2.qml" line="186"/>
<source>Save</source> <source>Save</source>
<translation></translation> <translation></translation>
</message> </message>

View file

@ -24,7 +24,7 @@ PageController::PageController(const QSharedPointer<ServersModel> &serversModel,
AndroidController::instance()->setNavigationBarColor(initialPageNavigationBarColor); AndroidController::instance()->setNavigationBarColor(initialPageNavigationBarColor);
#endif #endif
#if defined Q_OS_MACX #if defined Q_OS_MACX and !defined MACOS_NE
connect(this, &PageController::raiseMainWindow, []() { setDockIconVisible(true); }); connect(this, &PageController::raiseMainWindow, []() { setDockIconVisible(true); });
connect(this, &PageController::hideMainWindow, []() { setDockIconVisible(false); }); connect(this, &PageController::hideMainWindow, []() { setDockIconVisible(false); });
#endif #endif
@ -114,7 +114,7 @@ void PageController::showOnStartup()
} else { } else {
#if defined(Q_OS_WIN) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) #if defined(Q_OS_WIN) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID))
emit hideMainWindow(); emit hideMainWindow();
#elif defined Q_OS_MACX #elif defined Q_OS_MACX and !defined MACOS_NE
setDockIconVisible(false); setDockIconVisible(false);
#endif #endif
} }

View file

@ -5,12 +5,15 @@
#include <QDebug> #include <QDebug>
#include "notificationhandler.h" #include "notificationhandler.h"
#if defined(Q_OS_IOS) #if defined(Q_OS_IOS) || defined(MACOS_NE)
# include "platforms/ios/iosnotificationhandler.h" # include "platforms/ios/iosnotificationhandler.h"
// #elif defined(MACOS_NE)
// # include "platforms/ios/iosnotificationhandler.h"
#else #else
# include "systemtray_notificationhandler.h" # include "systemtray_notificationhandler.h"
#endif #endif
// static // static
NotificationHandler* NotificationHandler::create(QObject* parent) { NotificationHandler* NotificationHandler::create(QObject* parent) {
#if defined(Q_OS_IOS) #if defined(Q_OS_IOS)

View file

@ -8,7 +8,7 @@
#include "notificationhandler.h" #include "notificationhandler.h"
#include <QMenu> #include <QMenu>
#include <QSystemTrayIcon> #include <QSystemTrayIcon>'QMenu' file not found
class SystemTrayNotificationHandler : public NotificationHandler { class SystemTrayNotificationHandler : public NotificationHandler {
Q_OBJECT Q_OBJECT

Binary file not shown.

Binary file not shown.

138
deploy/build_macos_ne.sh Executable file
View file

@ -0,0 +1,138 @@
#!/bin/bash
echo "Build script for macOS Network Extension started ..."
set -o errexit -o nounset
while getopts n flag
do
case "${flag}" in
n) NOTARIZE_APP=1;;
esac
done
# Hold on to current directory
PROJECT_DIR=$(pwd)
DEPLOY_DIR=$PROJECT_DIR/deploy
mkdir -p $DEPLOY_DIR/build
BUILD_DIR=$DEPLOY_DIR/build
echo "Project dir: ${PROJECT_DIR}"
echo "Build dir: ${BUILD_DIR}"
APP_NAME=AmneziaVPN
APP_FILENAME=$APP_NAME.app
APP_DOMAIN=org.amneziavpn.package
PLIST_NAME=$APP_NAME.plist
OUT_APP_DIR=$BUILD_DIR/client
BUNDLE_DIR=$OUT_APP_DIR/$APP_FILENAME
PREBUILT_DEPLOY_DATA_DIR=$PROJECT_DIR/deploy/data/deploy-prebuilt/macos
DEPLOY_DATA_DIR=$PROJECT_DIR/deploy/data/macos
INSTALLER_DATA_DIR=$BUILD_DIR/installer/packages/$APP_DOMAIN/data
INSTALLER_BUNDLE_DIR=$BUILD_DIR/installer/$APP_FILENAME
DMG_FILENAME=$PROJECT_DIR/${APP_NAME}.dmg
# Setup provisioning profiles for main app and NE
echo "Setting up provisioning profiles..."
# Tạo thư mục Provisioning Profiles nếu chưa tồn tại
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles
# Setup provisioning profile cho main app
echo "Setting up provisioning profile for main app (AmneziaVPN)"
cp $PROJECT_DIR/deploy/AnhTVMacOSMain.provisionprofile ~/Library/MobileDevice/Provisioning\ Profiles/
macos_main_uuid=$(grep UUID -A1 -a ~/Library/MobileDevice/Provisioning\ Profiles/AnhTVMacOSMain.provisionprofile | grep -io "[-A-F0-9]\{36\}")
mv ~/Library/MobileDevice/Provisioning\ Profiles/AnhTVMacOSMain.provisionprofile ~/Library/MobileDevice/Provisioning\ Profiles/$macos_main_uuid.mobileprovision
# Setup provisioning profile cho Network Extension (NE)
echo "Setting up provisioning profile for Network Extension"
cp $PROJECT_DIR/deploy/AnhTVMacOSNE.mobileprovision ~/Library/MobileDevice/Provisioning\ Profiles/macos_ne.mobileprovision
macos_ne_uuid=$(grep UUID -A1 -a ~/Library/MobileDevice/Provisioning\ Profiles/macos_ne.mobileprovision | grep -io "[-A-F0-9]\{36\}")
mv ~/Library/MobileDevice/Provisioning\ Profiles/macos_ne.mobileprovision ~/Library/MobileDevice/Provisioning\ Profiles/$macos_ne_uuid.mobileprovision
# Giải mã và cài đặt chứng chỉ ký code
echo "Installing signing certificates..."
echo $MAC_TRUST_CERT_BASE64 | base64 --decode > mac_trust_cert.pem
echo $MAC_SIGNING_CERT_BASE64 | base64 --decode > mac_signing_cert.p12
# Cài đặt chứng chỉ vào keychain
security create-keychain -p password build.keychain
security default-keychain -s build.keychain
security unlock-keychain -p password build.keychain
security import mac_trust_cert.pem -k build.keychain -A
security import mac_signing_cert.p12 -k build.keychain -P $MAC_SIGNING_CERT_PASSWORD -A
# Thiết lập keychain cho quá trình ký
security set-key-partition-list -S apple-tool:,apple: -s -k password build.keychain
# Check if QIF_VERSION is properly set, otherwise set a default
if [ -z "${QIF_VERSION+x}" ]; then
echo "QIF_VERSION is not set, using default 4.6"
QIF_VERSION=4.6
fi
QIF_BIN_DIR="$QT_BIN_DIR/../../../Tools/QtInstallerFramework/$QIF_VERSION/bin"
# Checking environment
$QT_BIN_DIR/qt-cmake --version || { echo "Error: qt-cmake not found in $QT_BIN_DIR"; exit 1; }
cmake --version || { echo "Error: cmake not found"; exit 1; }
clang -v || { echo "Error: clang not found"; exit 1; }
# Build the Network Extension app
echo "Building Network Extension App..."
mkdir -p build-macos-ne
cd build-macos-ne
$QT_BIN_DIR/qt-cmake .. -GXcode -DQT_HOST_PATH=$QT_MACOS_ROOT_DIR -DMACOS_NE=TRUE
cmake --build . --config release --target AmneziaVPN -- -allowProvisioningUpdates # Thay đổi target phù hợp cho Network Extension
# Build and run tests here
echo "____________________________________"
echo "............Deploy.................."
echo "____________________________________"
# Package Network Extension
echo "Packaging Network Extension ..."
# Copy necessary data
cp -Rv $PREBUILT_DEPLOY_DATA_DIR/* $BUNDLE_DIR/Contents/macOS
$QT_BIN_DIR/macdeployqt $OUT_APP_DIR/$APP_FILENAME -always-overwrite -qmldir=$PROJECT_DIR
cp -av $BUILD_DIR/service/server/$APP_NAME-service $BUNDLE_DIR/Contents/macOS
cp -Rv $PROJECT_DIR/deploy/data/macos/* $BUNDLE_DIR/Contents/macOS
# Signing and notarizing the Network Extension
if [ "${MAC_CERT_PW+x}" ]; then
CERTIFICATE_P12=$DEPLOY_DIR/PrivacyTechAppleCertDeveloperId.p12
WWDRCA=$DEPLOY_DIR/WWDRCA.cer
KEYCHAIN=amnezia.build.macos.keychain
TEMP_PASS=tmp_pass
security create-keychain -p $TEMP_PASS $KEYCHAIN || true
security default-keychain -s $KEYCHAIN
security unlock-keychain -p $TEMP_PASS $KEYCHAIN
security import $WWDRCA -k $KEYCHAIN -T /usr/bin/codesign || true
security import $CERTIFICATE_P12 -k $KEYCHAIN -P $MAC_CERT_PW -T /usr/bin/codesign || true
echo "Signing Network Extension..."
/usr/bin/codesign --deep --force --verbose --timestamp -o runtime --sign "$MAC_SIGNER_ID" $BUNDLE_DIR
spctl -a -vvvv $BUNDLE_DIR || true
if [ "${NOTARIZE_APP+x}" ]; then
echo "Notarizing Network Extension bundle..."
/usr/bin/ditto -c -k --keepParent $BUNDLE_DIR $PROJECT_DIR/NE_Bundle_to_notarize.zip
xcrun notarytool submit $PROJECT_DIR/NE_Bundle_to_notarize.zip --apple-id $APPLE_DEV_EMAIL --team-id $MAC_TEAM_ID --password $APPLE_DEV_PASSWORD
rm $PROJECT_DIR/NE_Bundle_to_notarize.zip
sleep 300
xcrun stapler staple $BUNDLE_DIR
spctl -a -vvvv $BUNDLE_DIR || true
fi
fi
# Package installer, sign, and notarize (if needed)
# The rest of your installer packaging process similar to build_macos.sh

View file

@ -4,7 +4,7 @@ if(WIN32)
${CMAKE_CURRENT_LIST_DIR}/config/windows.xml.in ${CMAKE_CURRENT_LIST_DIR}/config/windows.xml.in
${CMAKE_BINARY_DIR}/installer/config/windows.xml ${CMAKE_BINARY_DIR}/installer/config/windows.xml
) )
elseif(APPLE AND NOT IOS) elseif(APPLE AND NOT IOS AND NOT MACOS_NE)
configure_file( configure_file(
${CMAKE_CURRENT_LIST_DIR}/config/macos.xml.in ${CMAKE_CURRENT_LIST_DIR}/config/macos.xml.in
${CMAKE_BINARY_DIR}/installer/config/macos.xml ${CMAKE_BINARY_DIR}/installer/config/macos.xml

View file

@ -6,6 +6,6 @@ project(${PROJECT})
set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_STANDARD_REQUIRED ON)
if(NOT IOS AND NOT ANDROID) if(NOT IOS AND NOT ANDROID AND NOT MACOS_NE)
add_subdirectory(server) add_subdirectory(server)
endif() endif()