How to extend kadmin
raeburn at MIT.EDU
Tue Oct 27 13:36:45 EDT 2009
On Oct 27, 2009, at 11:59, Nicolas Williams wrote:
>> * However, Nico notes that the way we marshal krb5_principal is
>> problematic for using rpcgen. I looked into this myself: we call
>> krb5_unparse_name on encode and krb5_parse_name on decode. Does
>> support app-defined encoding functions for particular fields? If
>> not, I
>> am doubtful that we will ever be in the position of being able to use
>> a .x file to define the kadmin protocol without starting over.
> No, you can't, but what you could do is declare the kadm5 krb5 princ
> data type to be "opaque" and then do the parsing/unparsing at the
> application layer.
I think you can leave the type undefined to rpcgen and use something
%bool_t xdr_foo(XDR *xdrs, foo *fooptr)
So you can supply an encoder/decoder (and typedef, etc) for an
individual type, without having to preprocess it all at the
application layer before calling into the RPC code.
More information about the krbdev