Bugzilla – Attachment 1627 Details for
Bug 1583
User principal name in AIX
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for user principal name (Unified diff)
auth-krb5.diff (text/plain), 1.56 KB, created by
Miguel Sanders
on 2009-04-23 21:25:27 AEST
(
hide
)
Description:
Patch for user principal name (Unified diff)
Filename:
MIME Type:
Creator:
Miguel Sanders
Created:
2009-04-23 21:25:27 AEST
Size:
1.56 KB
patch
obsolete
>--- auth-krb5.c 2006-08-05 03:39:40.000000000 +0200 >+++ auth-krb5.new.c 2009-04-23 13:20:07.000000000 +0200 >@@ -50,10 +50,14 @@ > #include <errno.h> > #include <unistd.h> > #include <string.h> > #include <krb5.h> > >+#ifdef _AIX >+#include <usersec.h> >+#endif /* _AIX */ >+ > extern ServerOptions options; > > static int > krb5_init(void *context) > { >@@ -77,18 +81,52 @@ > #endif > krb5_error_code problem; > krb5_ccache ccache = NULL; > int len; > >+#ifdef _AIX >+ len = 1; >+ char *authdomain = NULL; >+ char *authname = NULL; >+ setuserdb(S_READ); >+ getuserattr(authctxt->pw->pw_name, S_AUTHDOMAIN, &authdomain, SEC_CHAR); >+ getuserattr(authctxt->pw->pw_name, S_AUTHNAME, &authname, SEC_CHAR); >+ enduserdb(); >+ >+ if (authname) >+ len += strlen(authname); >+ else >+ len += strlen(authctxt->pw->pw_name); >+ >+ if (authdomain) >+ len += (strlen(authdomain) + 1); >+ >+ char *client = xmalloc(len); >+ if (authname) >+ strcpy(client,authname); >+ else >+ strcpy(client,authctxt->pw->pw_name); >+ >+ if (authdomain) { >+ strcat(client,"@"); >+ strcat(client,authdomain); >+ } >+#endif /* _AIX */ > temporarily_use_uid(authctxt->pw); > > problem = krb5_init(authctxt); > if (problem) > goto out; > >+#ifdef _AIX >+ problem = krb5_parse_name(authctxt->krb5_ctx, client, >+ &authctxt->krb5_user); >+ xfree(client); >+#else > problem = krb5_parse_name(authctxt->krb5_ctx, authctxt->pw->pw_name, > &authctxt->krb5_user); >+#endif /* _AIX */ > if (problem) > goto out; > > #ifdef HEIMDAL > problem = krb5_cc_gen_new(authctxt->krb5_ctx, &krb5_mcc_ops, &ccache);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1583
:
1621
|
1622
|
1627
|
1653
|
1654
|
1672
|
1713
|
1745