- gnutls, mbedtls: fix casing in log messages.
- src/tool_cfgable.h: drop unused header.
- appveyor.sh: variable style.
- cmakelint.sh: sync with libssh2, catch `.cmake.in` explicitly.
- examples: drop obsolete comments, exclamation marks.
- fix comment typos, casing.
Closes #19839
LANGUAGES C)
# CMake does not recognize some targets accurately. Touch up configuration manually as a workaround.
-if(WINDOWS_STORE AND MINGW) # mingw UWP build
+if(WINDOWS_STORE AND MINGW) # MinGW UWP build
# CMake (as of v3.31.2) gets confused and applies the MSVC rc.exe command-line
- # template to windres. Reset it to the windres template via 'Modules/Platform/Windows-windres.cmake':
+ # template to windres. Reset it to the windres template as in 'Modules/Platform/Windows-windres.cmake':
set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> -O coff <DEFINES> <INCLUDES> <FLAGS> <SOURCE> <OBJECT>")
elseif(DOS AND CMAKE_C_COMPILER_ID STREQUAL "GNU") # DJGPP
set(CMAKE_STATIC_LIBRARY_PREFIX "lib")
# Install custom cmake version
if [ -n "${CMAKE_VERSION:-}" ]; then
cmake_ver=$(printf '%02d%02d' \
- "$(echo "$CMAKE_VERSION" | cut -f1 -d.)" \
- "$(echo "$CMAKE_VERSION" | cut -f2 -d.)")
+ "$(echo "${CMAKE_VERSION}" | cut -f1 -d.)" \
+ "$(echo "${CMAKE_VERSION}" | cut -f2 -d.)")
if [ "${cmake_ver}" -ge '0320' ]; then
fn="cmake-${CMAKE_VERSION}-windows-x86_64"
else
/* tell libcurl we can use "any" auth, which lets the lib pick one, but it
also costs one extra round-trip and possibly sending of all the PUT
- data twice!!! */
+ data twice */
curl_easy_setopt(curl, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
/* set username and password for the authentication */
*/
#ifdef _MSC_VER
#ifndef _CRT_SECURE_NO_WARNINGS
-#define _CRT_SECURE_NO_WARNINGS /* for '_snprintf(), fopen(), localtime(),
+#define _CRT_SECURE_NO_WARNINGS /* for _snprintf(), fopen(), localtime(),
strerror() */
#endif
#endif
4. if you do not use a crypto engine:
4.1. set pKeyName to the filename of your client key
4.2. if the format of the key file is DER, set pKeyType to "DER"
-
- !! verify of the server certificate is not implemented here !!
-
- **** This example only works with libcurl 7.9.3 and later! ****
-
*/
int main(void)
char *key_type; /* format for private key (default: PEM) */
char *key_passwd; /* plain text private key password */
BIT(certinfo); /* gather lots of certificate info */
- BIT(earlydata); /* use tls1.3 early data */
+ BIT(earlydata); /* use TLS 1.3 early data */
BIT(enable_beast); /* allow this flaw for interoperability's sake */
BIT(no_revoke); /* disable SSL certificate revocation checks */
BIT(no_partialchain); /* do not accept partial certificate chains */
BIT(revoke_best_effort); /* ignore SSL revocation offline/missing revocation
list errors */
- BIT(native_ca_store); /* use the native ca store of operating system */
+ BIT(native_ca_store); /* use the native CA store of operating system */
BIT(auto_client_cert); /* automatically locate and use a client
certificate for authentication (Schannel) */
BIT(custom_cafile); /* application has set custom CA file */
STRING_SSL_PINNEDPUBLICKEY, /* public key file to verify peer against */
STRING_SSL_CIPHER_LIST, /* list of ciphers to use */
STRING_SSL_CIPHER13_LIST, /* list of TLS 1.3 ciphers to use */
- STRING_SSL_CRLFILE, /* crl file to check certificate */
+ STRING_SSL_CRLFILE, /* CRL file to check certificate */
STRING_SSL_ISSUERCERT, /* issuer cert file to check certificate */
STRING_SERVICE_NAME, /* Service name */
#ifndef CURL_DISABLE_PROXY
STRING_SSL_PINNEDPUBLICKEY_PROXY, /* public key file to verify proxy */
STRING_SSL_CIPHER_LIST_PROXY, /* list of ciphers to use */
STRING_SSL_CIPHER13_LIST_PROXY, /* list of TLS 1.3 ciphers to use */
- STRING_SSL_CRLFILE_PROXY, /* crl file to check certificate */
+ STRING_SSL_CRLFILE_PROXY, /* CRL file to check certificate */
STRING_SSL_ISSUERCERT_PROXY, /* issuer cert file to check certificate */
STRING_PROXY_SERVICE_NAME, /* Proxy service name */
#endif
return CURLE_OK;
}
- failf(data, "GnuTLS: cannot set ssl protocol");
+ failf(data, "GnuTLS: cannot set TLS protocol");
return CURLE_SSL_CONNECT_ERROR;
}
#else
rc = gnutls_certificate_set_x509_system_trust(creds);
if(rc < 0)
- infof(data, "error reading native ca store (%s), continuing anyway",
+ infof(data, "error reading native CA store (%s), continuing anyway",
gnutls_strerror(rc));
else {
infof(data, " Native: %d certificates from system trust", rc);
GNUTLS_X509_FMT_PEM);
creds_are_empty = creds_are_empty && (rc <= 0);
if(rc < 0) {
- infof(data, "error reading ca cert blob (%s)%s", gnutls_strerror(rc),
+ infof(data, "error reading CA cert blob (%s)%s", gnutls_strerror(rc),
(creds_are_empty ? "" : ", continuing anyway"));
if(creds_are_empty) {
ssl_config->certverifyresult = rc;
GNUTLS_X509_FMT_PEM);
creds_are_empty = creds_are_empty && (rc <= 0);
if(rc < 0) {
- infof(data, "error reading ca cert file %s (%s)%s",
+ infof(data, "error reading CA cert file %s (%s)%s",
config->CAfile, gnutls_strerror(rc),
(creds_are_empty ? "" : ", continuing anyway"));
if(creds_are_empty) {
GNUTLS_X509_FMT_PEM);
creds_are_empty = creds_are_empty && (rc <= 0);
if(rc < 0) {
- infof(data, "error reading ca cert file %s (%s)%s",
+ infof(data, "error reading CA cert file %s (%s)%s",
config->CApath, gnutls_strerror(rc),
(creds_are_empty ? "" : ", continuing anyway"));
if(creds_are_empty) {
rc = gnutls_certificate_set_x509_crl_file(creds, config->CRLfile,
GNUTLS_X509_FMT_PEM);
if(rc < 0) {
- failf(data, "error reading crl file %s (%s)",
+ failf(data, "error reading CRL file %s (%s)",
config->CRLfile, gnutls_strerror(rc));
return CURLE_SSL_CRL_BADFILE;
}
curlx_free(newblob);
if(ret < 0) {
mbedtls_strerror(ret, errorbuf, sizeof(errorbuf));
- failf(data, "Error importing ca cert blob - mbedTLS: (-0x%04X) %s",
+ failf(data, "Error importing CA cert blob - mbedTLS: (-0x%04X) %s",
-ret, errorbuf);
return CURLE_SSL_CERTPROBLEM;
}
if(ret < 0) {
mbedtls_strerror(ret, errorbuf, sizeof(errorbuf));
- failf(data, "Error reading ca cert file %s - mbedTLS: (-0x%04X) %s",
+ failf(data, "Error reading CA cert file %s - mbedTLS: (-0x%04X) %s",
ssl_cafile, -ret, errorbuf);
return CURLE_SSL_CACERT_BADFILE;
}
#else
- failf(data, "mbedtls: functions that use the file system not built in");
+ failf(data, "mbedTLS: functions that use the file system not built in");
return CURLE_NOT_BUILT_IN;
#endif
}
if(ret < 0) {
mbedtls_strerror(ret, errorbuf, sizeof(errorbuf));
- failf(data, "Error reading ca cert path %s - mbedTLS: (-0x%04X) %s",
+ failf(data, "Error reading CA cert path %s - mbedTLS: (-0x%04X) %s",
ssl_capath, -ret, errorbuf);
if(verifypeer)
return CURLE_SSL_CACERT_BADFILE;
}
#else
- failf(data, "mbedtls: functions that use the file system not built in");
+ failf(data, "mbedTLS: functions that use the file system not built in");
return CURLE_NOT_BUILT_IN;
#endif
}
return CURLE_SSL_CERTPROBLEM;
}
#else
- failf(data, "mbedtls: functions that use the file system not built in");
+ failf(data, "mbedTLS: functions that use the file system not built in");
return CURLE_NOT_BUILT_IN;
#endif
}
return CURLE_SSL_CERTPROBLEM;
}
#else
- failf(data, "mbedtls: functions that use the file system not built in");
+ failf(data, "mbedTLS: functions that use the file system not built in");
return CURLE_NOT_BUILT_IN;
#endif
}
return CURLE_SSL_CRL_BADFILE;
}
#else
- failf(data, "mbedtls: functions that use the file system not built in");
+ failf(data, "mbedTLS: functions that use the file system not built in");
return CURLE_NOT_BUILT_IN;
#endif
}
#else
if(ssl_crlfile) {
- failf(data, "mbedtls: crl support not built in");
+ failf(data, "mbedTLS: CRL support not built in");
return CURLE_NOT_BUILT_IN;
}
#endif
DEBUGASSERT(backend);
*pnwritten = 0;
connssl->io_need = CURL_SSL_IO_NEED_NONE;
- /* mbedtls is picky when a mbedtls_ssl_write) was previously blocked.
+ /* mbedTLS is picky when a mbedtls_ssl_write() was previously blocked.
* It requires to be called with the same amount of bytes again, or it
* will lose bytes, e.g. reporting all was sent but they were not.
* Remember the blocked length and use that when set. */
#
# SPDX-License-Identifier: curl
-# Possible not what we want, but cannot test, just silence the warnings
+# Possibly not what we want, but cannot test, just silence the warnings
allowfunc calloc
allowfunc free
allowfunc malloc
# strip off the leading ./ to make the grep regexes work properly
find . -type f | sed 's@^\./@@'
fi
-} | grep -E '(^CMake|/CMake|\.cmake$)' | grep -v -E '(\.h\.cmake|\.c)$' \
+} | grep -E '(^CMake|/CMake|\.cmake$|\.cmake\.in$)' | grep -v -E '(\.h\.cmake|\.c)$' \
| xargs \
cmake-lint \
--suppress-decorations \
*
***************************************************************************/
-#include <curl/mprintf.h>
#include "tool_setup.h"
#include "tool_sdecls.h"
#include "tool_urlglob.h"