publish changes

This commit is contained in:
Archie 2024-09-29 02:04:03 +00:00
parent afc5064a7b
commit ac2c6ac843
1605 changed files with 3354 additions and 3354 deletions

View file

@ -118,7 +118,7 @@
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h>
# include <arch.h>
# include <winsock2.h>
# include <ws2tcpip.h>
#endif

View file

@ -118,7 +118,7 @@
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h>
# include <arch.h>
# include <winsock2.h>
# include <ws2tcpip.h>
#endif

View file

@ -30,7 +30,7 @@ my $supressed; # whitelisted problems
my $file;
my $dir=".";
my $wlist;
my $windows_os = $^O eq 'MSWin32' || $^O eq 'msys' || $^O eq 'cygwin';
my $arch_os = $^O eq 'MSWin32' || $^O eq 'msys' || $^O eq 'cygwin';
my $verbose;
my %whitelist;
@ -65,7 +65,7 @@ sub readwhitelist {
open(W, "<$dir/checksrc.whitelist");
my @all=<W>;
for(@all) {
$windows_os ? $_ =~ s/\r?\n$// : chomp;
$arch_os ? $_ =~ s/\r?\n$// : chomp;
$whitelist{$_}=1;
}
close(W);
@ -263,7 +263,7 @@ sub scanfile {
checksrc_clear(); # for file based ignores
while(<R>) {
$windows_os ? $_ =~ s/\r?\n$// : chomp;
$arch_os ? $_ =~ s/\r?\n$// : chomp;
my $l = $_;
my $ol = $l; # keep the unmodified line for error reporting
my $column = 0;

View file

@ -698,7 +698,7 @@
/* Define to 1 if you have the winber.h header file. */
/* #undef HAVE_WINBER_H */
/* Define to 1 if you have the windows.h header file. */
/* Define to 1 if you have the arch.h header file. */
/* #undef HAVE_WINDOWS_H */
/* Define to 1 if you have the winldap.h header file. */

View file

@ -698,7 +698,7 @@
/* Define to 1 if you have the winber.h header file. */
/* #undef HAVE_WINBER_H */
/* Define to 1 if you have the windows.h header file. */
/* Define to 1 if you have the arch.h header file. */
/* #undef HAVE_WINDOWS_H */
/* Define to 1 if you have the winldap.h header file. */

View file

@ -610,7 +610,7 @@
/* Define to 1 if you have the winber.h header file. */
/* #undef HAVE_WINBER_H */
/* Define to 1 if you have the windows.h header file. */
/* Define to 1 if you have the arch.h header file. */
/* #undef HAVE_WINDOWS_H */
/* Define to 1 if you have the winldap.h header file. */

View file

@ -697,7 +697,7 @@
/* Define to 1 if you have the winber.h header file. */
/* #undef HAVE_WINBER_H */
/* Define to 1 if you have the windows.h header file. */
/* Define to 1 if you have the arch.h header file. */
/* #undef HAVE_WINDOWS_H */
/* Define to 1 if you have the winldap.h header file. */

View file

@ -141,7 +141,7 @@
#define HAVE_UNISTD_H 1
#endif
/* Define if you have the <windows.h> header file. */
/* Define if you have the <arch.h> header file. */
#define HAVE_WINDOWS_H 1
/* Define if you have the <winsock.h> header file. */

View file

@ -23,7 +23,7 @@
***************************************************************************/
/* ================================================================ */
/* lib/config-win32ce.h - Hand crafted config file for windows ce */
/* lib/config-win32ce.h - Hand crafted config file for arch ce */
/* ================================================================ */
/* ---------------------------------------------------------------- */
@ -119,7 +119,7 @@
#define HAVE_UNISTD_H 1
#endif
/* Define if you have the <windows.h> header file. */
/* Define if you have the <arch.h> header file. */
#define HAVE_WINDOWS_H 1
/* Define if you have the <winsock.h> header file. */

View file

@ -954,7 +954,7 @@ void Curl_sndbufset(curl_socket_t sockfd)
static int detectOsState = DETECT_OS_NONE;
if(detectOsState == DETECT_OS_NONE) {
if(Curl_verify_windows_version(6, 0, PLATFORM_WINNT,
if(Curl_verify_arch_version(6, 0, PLATFORM_WINNT,
VERSION_GREATER_THAN_EQUAL))
detectOsState = DETECT_OS_VISTA_OR_LATER;
else

View file

@ -728,7 +728,7 @@
/* Define to 1 if you have the winber.h header file. */
#cmakedefine HAVE_WINBER_H 1
/* Define to 1 if you have the windows.h header file. */
/* Define to 1 if you have the arch.h header file. */
#cmakedefine HAVE_WINDOWS_H 1
/* Define to 1 if you have the winldap.h header file. */

View file

@ -248,9 +248,9 @@
#endif
/*
* Include header files for windows builds before redefining anything.
* Use this preprocessor block only to include or exclude windows.h,
* winsock2.h, ws2tcpip.h or winsock.h. Any other windows thing belongs
* Include header files for arch builds before redefining anything.
* Use this preprocessor block only to include or exclude arch.h,
* winsock2.h, ws2tcpip.h or winsock.h. Any other arch thing belongs
* to any other further and independent block. Under Cygwin things work
* just as under linux (e.g. <sys/socket.h>) and the winsock headers should
* never be included when __CYGWIN__ is defined. configure script takes
@ -268,7 +268,7 @@
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h>
# include <arch.h>
# ifdef HAVE_WINSOCK2_H
# include <winsock2.h>
# ifdef HAVE_WS2TCPIP_H

View file

@ -82,7 +82,7 @@ CURLcode Curl_sspi_global_init(void)
* have both these DLLs (security.dll forwards calls to secur32.dll) */
/* Load SSPI dll into the address space of the calling process */
if(Curl_verify_windows_version(4, 0, PLATFORM_WINNT, VERSION_EQUAL))
if(Curl_verify_arch_version(4, 0, PLATFORM_WINNT, VERSION_EQUAL))
s_hSecDll = Curl_load_library(TEXT("security.dll"));
else
s_hSecDll = Curl_load_library(TEXT("secur32.dll"));

View file

@ -396,7 +396,7 @@ End Function
' Use Win32_ComputerSystem CurrentTimeZone property, because it automatically
' adjusts the Time Zone bias for daylight saving time; Win32_Time Zone Bias
' property does not.
' https://msdn.microsoft.com/en-us/library/windows/desktop/ms696015.aspx
' https://msdn.microsoft.com/en-us/library/arch/desktop/ms696015.aspx
Function LocalDateToUTC(localdate)
Dim item, offset
For Each item In GetObject("winmgmts:").InstancesOf("Win32_ComputerSystem")

View file

@ -60,9 +60,9 @@ typedef HMODULE (APIENTRY *LOADLIBRARYEX_FN)(LPCTSTR, HANDLE, DWORD);
#endif /* USE_WINDOWS_SSPI || (!CURL_DISABLE_TELNET && USE_WINSOCK) */
/*
* Curl_verify_windows_version()
* Curl_verify_arch_version()
*
* This is used to verify if we are running on a specific windows version.
* This is used to verify if we are running on a specific arch version.
*
* Parameters:
*
@ -76,7 +76,7 @@ typedef HMODULE (APIENTRY *LOADLIBRARYEX_FN)(LPCTSTR, HANDLE, DWORD);
*
* Returns TRUE if matched; otherwise FALSE.
*/
bool Curl_verify_windows_version(const unsigned int majorVersion,
bool Curl_verify_arch_version(const unsigned int majorVersion,
const unsigned int minorVersion,
const PlatformIdentifier platform,
const VersionCondition condition)

View file

@ -42,8 +42,8 @@ typedef enum {
PLATFORM_WINNT
} PlatformIdentifier;
/* This is used to verify if we are running on a specific windows version */
bool Curl_verify_windows_version(const unsigned int majorVersion,
/* This is used to verify if we are running on a specific arch version */
bool Curl_verify_arch_version(const unsigned int majorVersion,
const unsigned int minorVersion,
const PlatformIdentifier platform,
const VersionCondition condition);

View file

@ -2227,7 +2227,7 @@ CURLcode Curl_setopt(struct Curl_easy *data, CURLoption option,
* Set CA path info for SSL connection. Specify directory name of the CA
* certificates which have been prepared using openssl c_rehash utility.
*/
/* This does not work on windows. */
/* This does not work on arch. */
result = setstropt(&data->set.str[STRING_SSL_CAPATH_ORIG],
va_arg(param, char *));
#else
@ -2240,7 +2240,7 @@ CURLcode Curl_setopt(struct Curl_easy *data, CURLoption option,
* Set CA path info for SSL connection proxy. Specify directory name of the
* CA certificates which have been prepared using openssl c_rehash utility.
*/
/* This does not work on windows. */
/* This does not work on arch. */
result = setstropt(&data->set.str[STRING_SSL_CAPATH_PROXY],
va_arg(param, char *));
#else

View file

@ -353,7 +353,7 @@ struct ssl_primary_config {
bool verifypeer; /* set TRUE if this is desired */
bool verifyhost; /* set TRUE if CN/SAN must match hostname */
bool verifystatus; /* set TRUE if certificate status must be checked */
char *CApath; /* certificate dir (doesn't work on windows) */
char *CApath; /* certificate dir (doesn't work on arch) */
char *CAfile; /* certificate to verify peer against */
char *clientcert;
char *random_file; /* path to file containing "random" data */
@ -1480,8 +1480,8 @@ enum dupstring {
STRING_SET_RANGE, /* range, if used */
STRING_SET_REFERER, /* custom string for the HTTP referer field */
STRING_SET_URL, /* what original URL to work on */
STRING_SSL_CAPATH_ORIG, /* CA directory name (doesn't work on windows) */
STRING_SSL_CAPATH_PROXY, /* CA directory name (doesn't work on windows) */
STRING_SSL_CAPATH_ORIG, /* CA directory name (doesn't work on arch) */
STRING_SSL_CAPATH_PROXY, /* CA directory name (doesn't work on arch) */
STRING_SSL_CAFILE_ORIG, /* certificate file to verify peer against */
STRING_SSL_CAFILE_PROXY, /* certificate file to verify peer against */
STRING_SSL_PINNEDPUBLICKEY_ORIG, /* public key file to verify peer against */

View file

@ -130,7 +130,7 @@ schannel_connect_step1(struct connectdata *conn, int sockindex)
infof(data, "schannel: SSL/TLS connection with %s port %hu (step 1/3)\n",
hostname, conn->remote_port);
if(Curl_verify_windows_version(5, 1, PLATFORM_WINNT,
if(Curl_verify_arch_version(5, 1, PLATFORM_WINNT,
VERSION_LESS_THAN_EQUAL)) {
/* SChannel in Windows XP (OS version 5.1) uses legacy handshakes and
algorithms that may not be supported by all servers. */
@ -144,7 +144,7 @@ schannel_connect_step1(struct connectdata *conn, int sockindex)
connssl->use_alpn = conn->bits.tls_enable_alpn &&
!GetProcAddress(GetModuleHandleA("ntdll"),
"wine_get_version") &&
Curl_verify_windows_version(6, 3, PLATFORM_WINNT,
Curl_verify_arch_version(6, 3, PLATFORM_WINNT,
VERSION_GREATER_THAN_EQUAL);
#else
connssl->use_alpn = false;
@ -248,7 +248,7 @@ schannel_connect_step1(struct connectdata *conn, int sockindex)
memset(connssl->cred, 0, sizeof(struct curl_schannel_cred));
connssl->cred->refcount = 1;
/* https://msdn.microsoft.com/en-us/library/windows/desktop/aa374716.aspx
/* https://msdn.microsoft.com/en-us/library/arch/desktop/aa374716.aspx
*/
sspi_status =
s_pSecFn->AcquireCredentialsHandle(NULL, (TCHAR *)UNISP_NAME,
@ -355,7 +355,7 @@ schannel_connect_step1(struct connectdata *conn, int sockindex)
return CURLE_OUT_OF_MEMORY;
/* Schannel InitializeSecurityContext:
https://msdn.microsoft.com/en-us/library/windows/desktop/aa375924.aspx
https://msdn.microsoft.com/en-us/library/arch/desktop/aa375924.aspx
At the moment we don't pass inbuf unless we're using ALPN since we only
use it for that, and Wine (for which we currently disable ALPN) is giving
@ -529,7 +529,7 @@ schannel_connect_step2(struct connectdata *conn, int sockindex)
if(!host_name)
return CURLE_OUT_OF_MEMORY;
/* https://msdn.microsoft.com/en-us/library/windows/desktop/aa375924.aspx
/* https://msdn.microsoft.com/en-us/library/arch/desktop/aa375924.aspx
*/
sspi_status = s_pSecFn->InitializeSecurityContext(
&connssl->cred->cred_handle, &connssl->ctxt->ctxt_handle,
@ -950,7 +950,7 @@ schannel_send(struct connectdata *conn, int sockindex,
/* copy data into output buffer */
memcpy(outbuf[1].pvBuffer, buf, len);
/* https://msdn.microsoft.com/en-us/library/windows/desktop/aa375390.aspx */
/* https://msdn.microsoft.com/en-us/library/arch/desktop/aa375390.aspx */
sspi_status = s_pSecFn->EncryptMessage(&connssl->ctxt->ctxt_handle, 0,
&outbuf_desc, 0);
@ -1163,7 +1163,7 @@ schannel_recv(struct connectdata *conn, int sockindex,
InitSecBuffer(&inbuf[3], SECBUFFER_EMPTY, NULL, 0);
InitSecBufferDesc(&inbuf_desc, inbuf, 4);
/* https://msdn.microsoft.com/en-us/library/windows/desktop/aa375348.aspx
/* https://msdn.microsoft.com/en-us/library/arch/desktop/aa375348.aspx
*/
sspi_status = s_pSecFn->DecryptMessage(&connssl->ctxt->ctxt_handle,
&inbuf_desc, 0, NULL);
@ -1311,7 +1311,7 @@ cleanup:
*/
if(len && !connssl->decdata_offset && connssl->recv_connection_closed &&
!connssl->recv_sspi_close_notify) {
bool isWin2k = Curl_verify_windows_version(5, 0, PLATFORM_WINNT,
bool isWin2k = Curl_verify_arch_version(5, 0, PLATFORM_WINNT,
VERSION_EQUAL);
if(isWin2k && sspi_status == SEC_E_OK)
@ -1394,7 +1394,7 @@ void Curl_schannel_close(struct connectdata *conn, int sockindex)
int Curl_schannel_shutdown(struct connectdata *conn, int sockindex)
{
/* See https://msdn.microsoft.com/en-us/library/windows/desktop/aa380138.aspx
/* See https://msdn.microsoft.com/en-us/library/arch/desktop/aa380138.aspx
* Shutting Down an Schannel Connection
*/
struct Curl_easy *data = conn->data;
@ -1618,7 +1618,7 @@ static CURLcode verify_certificate(struct connectdata *conn, int sockindex)
Right now we're only asking for the first preferred alternative name.
Instead we'd need to do all via CERT_NAME_SEARCH_ALL_NAMES_FLAG
(if WinCE supports that?) and run this section in a loop for each.
https://msdn.microsoft.com/en-us/library/windows/desktop/aa376086.aspx
https://msdn.microsoft.com/en-us/library/arch/desktop/aa376086.aspx
curl: (51) schannel: CertGetNameString() certificate hostname
(.google.com) did not match connection (google.com)
*/

View file

@ -17,14 +17,14 @@ project "curl-lib"
"**.c"
}
filter { "system:windows" }
filter { "system:arch" }
defines { "USE_SCHANNEL", "USE_WINDOWS_SSPI" }
links "crypt32"
filter { "system:macosx" }
defines { "USE_DARWINSSL" }
filter { "system:not windows", "system:not macosx" }
filter { "system:not arch", "system:not macosx" }
defines { "USE_MBEDTLS" }
filter { "system:linux or bsd or solaris" }