]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
libsspwin32: SSP_LogonUser takes char * parameters
authorAmos Jeffries <squid3@treenet.co.nz>
Sat, 13 Oct 2012 05:29:03 +0000 (23:29 -0600)
committerAmos Jeffries <squid3@treenet.co.nz>
Sat, 13 Oct 2012 05:29:03 +0000 (23:29 -0600)
There is no need to cast these parameters via void*. Both the library
and the basic auth helper(s) that use it work with char* strings.

include/sspwin32.h
lib/sspwin32.cc

index 8e7a2ec688affefa40128988317f1292da46f9f5..666e918e0436c36938fe19e463b4791fa68d0cd8 100644 (file)
@@ -70,7 +70,7 @@ extern "C" {
 
     HMODULE LoadSecurityDll(int, const char *);
     void UnloadSecurityDll(void);
-    BOOL WINAPI SSP_LogonUser(PTSTR, PTSTR, PTSTR);
+    BOOL WINAPI SSP_LogonUser(unsigned char *, unsigned char *, unsigned char *);
     BOOL WINAPI SSP_ValidateNTLMCredentials(PVOID, int, char *);
     const char * WINAPI SSP_ValidateNegotiateCredentials(PVOID, int, PBOOL, int *, char *);
     const char * WINAPI SSP_MakeChallenge(PVOID, int);
index 32acd0fb8a837c41c1a2ff233dd4d12fc1ae7713..ee857b688abba8b00195a492dafc9be856b96011 100644 (file)
@@ -422,11 +422,11 @@ BOOL WINAPI SSP_LogonUser(PTSTR szUser, PTSTR szPassword, PTSTR szDomain)
 
         /* Initialize auth identity structure */
         ZeroMemory(&ai, sizeof(ai));
-        ai.Domain = (void *)szDomain;
+        ai.Domain = (unsigned char *)szDomain;
         ai.DomainLength = lstrlen(szDomain);
-        ai.User = (void *)szUser;
+        ai.User = (unsigned char *)szUser;
         ai.UserLength = lstrlen(szUser);
-        ai.Password = (void *)szPassword;
+        ai.Password = (unsigned char *)szPassword;
         ai.PasswordLength = lstrlen(szPassword);
 #if defined(UNICODE) || defined(_UNICODE)
         ai.Flags = SEC_WINNT_AUTH_IDENTITY_UNICODE;