OpenVPN Connect unable to import profile from url

Official client software for OpenVPN Access Server and OpenVPN Cloud.
Post Reply
vicn1222
OpenVPN User
Posts: 25
Joined: Mon Jul 12, 2021 2:31 pm

OpenVPN Connect unable to import profile from url

Post by vicn1222 » Wed Oct 19, 2022 6:35 pm

Hi,

I can download client.ovpn and import into OpenVPN Connect via file on my iPhone.

However, when I try to import via URL, it complains: "The operation couldn't be completed (ErrorParserDomain error 103)".

I have set up the url as https://www.mysitename.com/cert.ovpn, which re-write to https://www.mysitename.com/cert.php in .htaccess

The cert.php is like below. I tried to search all over the google, but unable to find answer. Can someone help me on this?

Thank you!

Code: Select all

<?php

header( "Content-type: application/x-openvpn-profile" );
header( "X-OpenVPN: 1" );
echo file_get_contents( __DIR__ . "/client.ovpn" );

?>
Last edited by Pippin on Wed Oct 19, 2022 6:55 pm, edited 1 time in total.

vicn1222
OpenVPN User
Posts: 25
Joined: Mon Jul 12, 2021 2:31 pm

Re: OpenVPN Connect unable to import profile from url

Post by vicn1222 » Wed Oct 19, 2022 8:46 pm

OK, I finally get it through and log in with the URL.

However, it asks to enter password each time I attempt to connect. How can I save the password in my iPhone when connecting through URL?

I search around and people say to do like below

Code: Select all

auth-user-pass pass.txt
But it is iPhone, I can't create the pass.txt. Is there other trick? Thank you!

Thank you!

vicn1222
OpenVPN User
Posts: 25
Joined: Mon Jul 12, 2021 2:31 pm

Re: OpenVPN Connect unable to import profile from url

Post by vicn1222 » Wed Oct 19, 2022 8:54 pm

OK, I got it.

It need to import profile first, then come back to login and save password.

yardslave
OpenVpn Newbie
Posts: 1
Joined: Wed Jan 25, 2023 10:44 pm

Re: OpenVPN Connect unable to import profile from url

Post by yardslave » Wed Jan 25, 2023 10:52 pm

Looking at the original post in the thread by vicn1222, I do not see a solution addressing the issue. (I have the ErrorParserDomain error 103 as well.) It does not seem to allow the cert, key, or ovpn files via the URL. Following the EdgeRouter - OpenVPN Server pages for my ER-4, I've got a windows box working, but I'm looking to restore operations on my iPhone and can't see to figure it out.

UPDATED WITH SOLUTION
(At least for my problem) :D
Joined Support forum and found another thread that addressed this.

https://forums.openvpn.net/viewtopic.php?t=32453


So, if your look there to find a possible solution. (Join the FREE Forum) :roll:

sadeghmk
OpenVpn Newbie
Posts: 1
Joined: Sat May 20, 2023 8:45 am

Re: OpenVPN Connect unable to import profile from url

Post by sadeghmk » Sat May 20, 2023 8:49 am

How was your problem solved?
Please guide me, I need your help to fix this problem
For example, the file address is as follows
https://example.com/sv.ovpn
centos 7 + httpd server

Post Reply