-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Siri Shortcuts integration for iOS #8
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
… intent Signed-off-by: Alessio Nossa <[email protected]>
Thank you! This is a good solution if your WireGuard server is behind a daily changing public IP and you use dynDNS to update the IP (WG does not resolve endpoint domains after the tunnel has been enabled). |
I needed this integration for the same reason basically: to update the Peers' Endpoint values that change often. On desktop, you can use wgctrl, but on iOS, there was no other way than to manually update the Endpoint field. It all started with the great and detailed article WireGuard Endpoint Discovery and NAT Traversal using DNS-SD by Jordan Whited that I suggest you read if you need to reach a device behind NAT (or with a dynamic IP, without using third-party services). |
That sounds very nice! When do you think the update will be available? |
I don’t know when the update will be available: the implementation is complete and ready to be merged, we now have to wait for the maintainers to review the changes, build the app and submit the update to App Store! |
Are you meant to send PRs here? The official repo is at https://git.zx2c4.com/wireguard-apple, but I don't see a clear way of submitting patches there |
Ways to contribute are listed on the WireGuard website and I've done whatever needed to be done, in fact, the changes are already published in the main repository, in the dedicated branch. They just need to be merged into the main branch, but I think this can be done by @zx2c4 only. |
Oh, I didn't realise sorry :) This PR is working great for me, by the way! |
This is a great addition! I sure hope it gets merged. I don’t know of any other VPN client on iOS with this level of Shortcut integration. |
Update 23/02/2022, from maintainers:
|
It has been six months, I hope this gets merged. 👍🏼 It's very useful to have. |
Since Apple is releasing a new framework for the integration with Siri and the Shortcuts app - App Intents - I think it makes sense to rewrite this integration with the new framework. Otherwise, we start supporting a new functionality with a framework that is almost deprecated. |
I know that they're [apple] still working on the new Framework with new features still to be added, but would this be a relatively quick deployment to production since some of the work appears to have already been done? Thanks! |
Actual problem 😄 need to merge and publish application |
Wondering why this is marked as a draft? Should I hold off reviewing this? |
@zx2c4 Yes, I would like to reimplement the integration using the new AppIntents framework. The biggest benefit is that we don’t need to open the app anymore to update the configuration because the code of App Intents can be in the Main App Target too. |
c37881b
to
2fec12a
Compare
Hi! |
Could we get it merged in its current state and then follow up later with a new version using the newer App Intents API? I've been waiting for the ability to connect to a VPN via a Siri Shortcut for years now and I feel it was right at our fingertips. |
Seeing the demand for this feature, I'll try to take a look at this today.
This can be done, but would add a lot of boilerplate code that is more or less already outdated. |
bacfe8f
to
014bf05
Compare
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
014bf05
to
c1d7199
Compare
Here is a demo on iOS of the implementation am submitting for review RPReplay_Final1681252092.MP4TheApp Intents are available and correctly working with macOS app too Currently, the App Intents are localized in English only, however they are ready for localization in other languages since all the Strings are in |
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
4627c12
to
97bf1c1
Compare
@alessionossa Some of WireGuard iOS users are on versions lower than 16.4 due to certain compatibility reasons. Connect/Disconnect feature in this implementation would be a great boon for us! |
@Marvur the framework used for the implementation is only available starting from iOS 16. Are there really big differences in compatibility between iOS 16.0 and iOS 16.4, considering they are in the same major release? Anyway I think this PR is ready for review, and other Shortcuts actions can be discussed and implemented later. |
Users on iOS 16 - 16.1.2 are the target group. "Connect VPN" shortcut action doesn't exist on these versions of iOS and it will be super helpful to have that inbuilt in Wireguard. |
Is there anything holding this PR back? Would be really useful to have this one merged! |
The PR is just waiting @zx2c4 review I think; but he has been prioritizing other platforms and repository for some time. |
I needed this so bad for the fact that my ISP uses dynamic IP, would really appreciate if @zx2c4 could take some time review/merging this. |
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Signed-off-by: Alessio Nossa <[email protected]>
Any updates? I need this! |
@HuJK while I’m also looking forward to this PR’s review, I think you can accomplish your goal using system’s actions in Shortcuts. In fact, the current implementation doesn’t have any action to turn VPN Configurations On/Off because there’s already a system’s action since iOS 16 dedicated to that. |
Add support for Siri Shortcuts (and the Shortcuts app) for iOS.
Three intents have been implemented:
The configuration of the Intents Extension was done by looking at the configuration of the Network Extension.
Intents (actions) are fully functional on iOS 14.0+, I will test them on iOS 13 as soon as I can get a device with this iOS version since the Simulator is very limited in this case. Anyway, this integration does not alter the functionality of the app.
UPDATE 07/02/2022
Tested on iOS 12, donated Intents are working correctly (turn on and turn off tunnels). User configurable actions in the Shortcuts app are not available on this iOS version for third-party apps.