OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
2.2 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../autofs/autofs-5.0.5-heimdal.patch
  5. # Copyright (C) 2011 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. Description: Fix to build against heimdal
  17. Origin: Gentoo Linux
  18. http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/net-fs/autofs/files/autofs-5.0.3-heimdal.patch
  19. --- autofs-5.0.5/modules/cyrus-sasl.c.orig 2011-03-08 12:17:15.342696284 +0100
  20. +++ autofs-5.0.5/modules/cyrus-sasl.c 2011-03-08 12:28:46.326696273 +0100
  21. @@ -64,6 +64,15 @@
  22. #endif
  23. #endif
  24. +/**
  25. + * The type of a principal is different for MIT Krb5 and Heimdal.
  26. + * These macros are provided by Heimdal, and introduced here for MIT.
  27. + */
  28. +#ifndef krb5_realm_length
  29. +#define krb5_realm_length(r) ((r).length)
  30. +#define krb5_realm_data(r) ((r).data)
  31. +#endif
  32. +
  33. /*
  34. * Once a krb5 credentials cache is setup, we need to set the KRB5CCNAME
  35. * environment variable so that the library knows where to find it.
  36. @@ -451,11 +460,11 @@
  37. /* setup a principal for the ticket granting service */
  38. ret = krb5_build_principal_ext(ctxt->krb5ctxt, &tgs_princ,
  39. - krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)->length,
  40. - krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)->data,
  41. + krb5_realm_length(*krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)),
  42. + krb5_realm_data(*krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)),
  43. strlen(KRB5_TGS_NAME), KRB5_TGS_NAME,
  44. - krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)->length,
  45. - krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)->data,
  46. + krb5_realm_length(*krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)),
  47. + krb5_realm_data(*krb5_princ_realm(ctxt->krb5ctxt, krb5_client_princ)),
  48. 0);
  49. if (ret) {
  50. error(logopt,