Hi

 

I came across a problem in latest 1.6.3 and 1.5.4 Kerberos source code where GetWindowsDirectory() returns private Windows System directory path for every logon user when windows terminal services are installed on a system.

 

See http://msdn2.microsoft.com/en-us/library/ms724454(VS.85).aspx Microsoft article which explains the GetWindowsDirectory() API. I think it may be good idea to use GetSystemWindowsDirectory to find the Windows System Directory name to locate the Windows Kerberos Configuration file.

 

krb5-1.6.3/src/windows/kfwlogon/kfwlogon.c:        GetWindowsDirectory(filename, sizeof(filename));

krb5-1.6.3/src/windows/identity/plugins/krb5/krb5funcs.c:        GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/windows/identity/plugins/krb5/krb5funcs.c:        GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/windows/identity/plugins/krb5/krb5funcs.c:            GetWindowsDirectoryA(krbConFile,sizeof(krbConFile));

krb5-1.6.3/src/windows/identity/plugins/krb5/krb5funcs.c:                GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/windows/identity/plugins/krb4/krb4funcs.c:        GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/windows/identity/plugins/krb4/krb4funcs.c:        GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/windows/identity/plugins/krb4/krb4funcs.c:            GetWindowsDirectoryA(krbConFile,sizeof(krbConFile));

krb5-1.6.3/src/windows/identity/plugins/krb4/krb4funcs.c:            GetWindowsDirectoryA(confname,szConfname);

krb5-1.6.3/src/lib/krb5/os/init_os_ctx.c:    UINT size = GetWindowsDirectory(0, 0);

krb5-1.6.3/src/lib/krb5/os/init_os_ctx.c:        GetWindowsDirectory(*pname, size);

krb5-1.6.3/src/lib/krb5/os/ktdefname.c:     len= GetWindowsDirectory( defname, sizeof(defname)-2 );

krb5-1.6.3/src/lib/krb5/os/ccdefname.c:                    int len = GetWindowsDirectory(p, size);

krb5-1.6.3/src/lib/krb4/win_store.c:    rc = GetWindowsDirectory(defname, sizeof(defname) - 1);

krb5-1.6.3/src/lib/krb4/win_store.c:    rc = GetWindowsDirectory(defname, sizeof(defname) - 1);

 

SAM SHARMA