Switch from IP address to addons.supertuxkart.net (including new

certificate).
This commit is contained in:
hiker 2014-12-10 23:53:47 +11:00
parent f0ddaa50a5
commit c0c4357331
4 changed files with 27 additions and 30 deletions

View File

@ -1,24 +0,0 @@
-----BEGIN CERTIFICATE-----
MIIDxzCCAq+gAwIBAgIJALqBW1fbqtOkMA0GCSqGSIb3DQEBCwUAMHoxCzAJBgNV
BAYTAlVTMRMwEQYDVQQIDApTb21lLVN0YXRlMRUwEwYDVQQKDAxTdXBlclR1eEth
cnQxFzAVBgNVBAMMDjEwNC4xMzEuMTkzLjQ0MSYwJAYJKoZIhvcNAQkBFhdoZW5y
aWNoc2pvZXJnQGdtYWlsLmNvbTAeFw0xNDEyMDUwMTE5MjJaFw0xNTEyMDUwMTE5
MjJaMHoxCzAJBgNVBAYTAlVTMRMwEQYDVQQIDApTb21lLVN0YXRlMRUwEwYDVQQK
DAxTdXBlclR1eEthcnQxFzAVBgNVBAMMDjEwNC4xMzEuMTkzLjQ0MSYwJAYJKoZI
hvcNAQkBFhdoZW5yaWNoc2pvZXJnQGdtYWlsLmNvbTCCASIwDQYJKoZIhvcNAQEB
BQADggEPADCCAQoCggEBANeRfUfScX6jrLGWZNJBazS3MYzdOPo9hg01YWTlaZaX
pGT/fZdgnZ7eKSuAgbcOPeXDldHO2rfK+6iOgFf7pYI10DhdtXdPl3geBZzU7NC4
V50iH6vkTqiGSCn5pI+1QsAiBdUX7kT/nutL15cjTk0GBVZ6o2OUPFckXDviexOO
MVDbF+9D/GQ9wa4srpTN7yly7Mz2uE8dXS2ewof5JKhjJWJEArSsPvIyU7W/f683
XIzdFM5VZCKVjYdVb5l08ZLh0oseX7muevNi5CkdPUZdjksDhp6B3oS5kMwT3niT
LONe8BB0LklqNEqko46y46Lce6kd+xMkYOTZQJ6Ib/ECAwEAAaNQME4wHQYDVR0O
BBYEFNswiOKhNkwUBj+kAxnVIFePHoJuMB8GA1UdIwQYMBaAFNswiOKhNkwUBj+k
AxnVIFePHoJuMAwGA1U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ZtfbrJn4
ZEfkOjl0Abv6gET4sQOXv0KioUdEJwzFCwKFLZVcuOrscmcHBOhgD3EruVvprIJ0
wZ3z1wIDAQABo1AwTjAdBgNVHQ4EFgQUmQwaPsD+ylVUUsUXMAYpUlnVbNwwHwYD
VR0jBBgwFoAUmQwaPsD+ylVUUsUXMAYpUlnVbNwwDAYDVR0TBAUwAwEB/zANBgkq
hkiG9w0BAQsFAAOCAQEASyl6BMpnZhJlirDL84/RkVeVjBkr7x68UFAblmKjgfGg
pRbYPNSld0IrfZ4pcrDAUkg9WJb0Zxuh0oYiV+RjdW/6s5mF/qiSv8V60xb2myRd
z90ZGfhB5SAECI5zfIZSmsMjOEjKjuz8S26aEtJe8Vq7GF2P7/889lfNXrbvIkZX
HQpx2P+T07zy++6Ca/K2vmWcf1a+GrN+o0nZTYbz/2r/JJwXdWqT1ZmtEA9GNwvZ
J8HhgvspgjgVP/EURUUhOaQ8zfhriU5CJAIuhMhzW7oOBPHxxtxme3auAfxi5zpK
wRNluCayrrjhy2I8mABRnBqgMwAQUIrgk9IU6SyQxw==
-----END CERTIFICATE-----

View File

@ -733,7 +733,7 @@ namespace UserConfigParams
"A random number to avoid duplicated reports.") );
PARAM_PREFIX StringUserConfigParam m_server_hw_report
PARAM_DEFAULT( StringUserConfigParam( "http://104.131.193.44:8080",
PARAM_DEFAULT( StringUserConfigParam( "http://addons.supertuxkart.net:8080",
"hw-report-server",
&m_hw_report_group,
"The server used for reporting statistics to."));
@ -757,7 +757,7 @@ namespace UserConfigParams
"Everything related to online play.") );
PARAM_PREFIX StringUserConfigParam m_server_multiplayer
PARAM_DEFAULT( StringUserConfigParam( "https://104.131.193.44/api/",
PARAM_DEFAULT( StringUserConfigParam( "https://addons.supertuxkart.net/api/",
"server_multiplayer",
&m_online_group,
"The server used for online multiplayer."));
@ -775,7 +775,7 @@ namespace UserConfigParams
"Addon and news related settings") );
PARAM_PREFIX StringUserConfigParam m_server_addons
PARAM_DEFAULT( StringUserConfigParam("http://104.131.193.44/dl/xml",
PARAM_DEFAULT( StringUserConfigParam("http://addons.supertuxkart.net/dl/xml",
"server_addons",
&m_addon_group,
"The server used for addon."));

View File

@ -175,14 +175,14 @@ namespace Online
{
// https, load certificate info
struct curl_slist *chunk = NULL;
chunk = curl_slist_append(chunk, "Host: api.stkaddons.net");
chunk = curl_slist_append(chunk, "Host: addons.supertuxkart.net");
curl_easy_setopt(m_curl_session, CURLOPT_HTTPHEADER, chunk);
CURLcode error = curl_easy_setopt(m_curl_session, CURLOPT_CAINFO,
file_manager->getAsset("104.131.193.44.pem").c_str());
file_manager->getAsset("addons.supertuxkart.net.pem").c_str());
if (error != CURLE_OK)
{
Log::error("HTTPRequest", "Error setting CAINFO to '%s'",
file_manager->getAsset("104.131.193.44.pem").c_str());
file_manager->getAsset("addons.supertuxkart.net.pem").c_str());
Log::error("HTTPRequest", "Error %d: '%s'.", error,
curl_easy_strerror(error));
}