You are here
John Markey - Fri, 2025/01/31 - 23:39
I was wondering if there's an easy way to update Owncloud to the newest ver?
When I go to admin / setting / updater
I get the following error
(cURL error 60: SSL: no alternative certificate subject name matches target host name '10.9.70.175' (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://10.9.70.175/index.php/occ/config:list )
Thank you
John M
Forum:
It's a hostname SSL/TLS certificate mismatch issue
Hi John
Given the error message, I'm guessing that you are running your appliance locally -because 10.9.70.175 is a "private network" IP.
TBH I'm not sure why it's actually an issue because I don't know why ownCloud would care about that? Regardless, it obviously does...
The core issue is that your SSL/TLS certificate doesn't match the "hostname" that you are using - i.e. "10.9.70.175".
I won't go into further details of that, but even if you did use the default hostname ("owncloud" - the hostname in the default self-signed cert generated at firstboot) it likely still wouldn't work. By default curl will also choke on self-signed certs. FWIW on the command line it can be worked around using curl's "--insecure" switch (assuming that 10.9.70.175 is the IP of your ownCloud server then it's not actually insecure). Regardless, I'm not sure if/how that switch can be passed to curl via PHP code.
So if you can access your server via a FQDN (fully qualified domain name - e.g. www.example.com) and your server has a "proper" CA signed certificate, then try using putting the domain in your browser address bar instead of the IP address and then the update should work.
If that isn't possible and ownCloud will allow update using a vanilla http URL then using http instead of https might be another way to get around the error? As you're likely already aware, by default TurnKey ownCloud redirects http to https. Assuming that I am right up to here and your server is running in a LAN and isn't publicly available, it's pretty easy to disable that.
It's probably possible via Webmin, but I'm a CLI guy, so will only cover that. If you're not familiar with editing files in a terminal, I suggest using 'nano' (which is pre-installed). The Apache (webserver) config file to edit is '/etc/apache2/sites-available/owncloud.conf'. I.e. using nano like this:
To disable the redirect, add a '#' prefix to the Rewrite lines. When updated, the lines should look like this:
IIRC you use >Ctrl>>X> to save and exit - but it should say down the bottom of the screen. After doing that, restart Apache:
Then because the redirect sends a HTTP code 301 (permanent redirect) you also need to clear the relevant cache and cookies in your web browser. Or alternatively, you could just use a separate "private"/"incognito" browser window.
Then try again... If that doesn't work, then the next thing to try is a command line upgrade. ownCloud do provide CLI upgrade instructions in their docs, but they're pretty poor IMO so I'm not going to link to them. When I get a chance, I'll provide some better upgrade instructions here on the website. Or better still I might just write an upgrade script. If the above doesn't work, let me know and I'll make doing that a higher priority.
If the above doesn't work and you're happy to press ahead using their docs, the only thing you should need to do is to is to install 'sudo':
Either way, let me know how you go.
Add new comment