mono
mono copied to clipboard
Support for Heimdal
external/corefx/src/Native/Unix/System.Net.Security.Native/pal_gssapi.c (https://github.com/mono/corefx/blob/main/src/Native/Unix/System.Net.Security.Native/pal_gssapi.c) seems to already support Heimdal (one of implementations of Kerberos):
#if HAVE_GSSFW_HEADERS
#include <GSS/GSS.h>
#else
#if HAVE_HEIMDAL_HEADERS
#include <gssapi/gssapi.h>
#include <gssapi/gssapi_krb5.h>
#else
#include <gssapi/gssapi_ext.h>
#include <gssapi/gssapi_krb5.h>
#endif
#endif
However configure.ac of Mono fails to detect headers of Heimdal. It only searches for headers of MIT Kerberos V:
checking for GSS/GSS.h... no
checking for gssapi/gssapi_ext.h... no
checking for GSS_SPNEGO_MECHANISM... no
...
checking Mono.Native support... configure: WARNING: GSS is not enabled, it requires libkrb5-dev package
Linux
...
~~Patch: mono-6.12.0.122-heimdal.patch.txt~~
Improved patch: mono-6.12.0.122-gss.patch.txt
(Improved patch adds support for --enable-gss / --disable-gss option.)
You should send a pull request so that it can be reviewed and merged.
It fails to detect even kerberos and gss.
@Arfrever Does not work for me with gss enabled even with your patch. Kerberos and GSS installed, neither is picked up.
CC ../../external/corefx/src/Native/Unix/System.Net.Security.Native/libmono_native_la-pal_gssapi.lo
In file included from ../../external/corefx/src/Native/Unix/System.Net.Security.Native/pal_gssapi.c:7:
../../external/corefx/src/Native/Unix/System.Net.Security.Native/pal_gssapi.h:47: warning: ignoring '#pragma clang diagnostic' [-Wunknown-pragmas]
47 | #pragma clang diagnostic push
|
../../external/corefx/src/Native/Unix/System.Net.Security.Native/pal_gssapi.h:48: warning: ignoring '#pragma clang diagnostic' [-Wunknown-pragmas]
48 | #pragma clang diagnostic ignored "-Wpadded"
|
../../external/corefx/src/Native/Unix/System.Net.Security.Native/pal_gssapi.h:54: warning: ignoring '#pragma clang diagnostic' [-Wunknown-pragmas]
54 | #pragma clang diagnostic pop
|
cc1: note: unrecognized command-line option '-Wno-typedef-redefinition' may have been intended to silence earlier diagnostics
CCLD libmono-native.la
ld: framework not found GSS
collect2: error: ld returned 1 exit status
Ah, macOS build has been broken by https://github.com/mono/mono/issues/14793
@Arfrever We should use kerberos5 or heimdal on macOS < 10.14.