r8148: - make the PAC generation code a bit more readable and add some outof memory...
authorStefan Metzmacher <metze@samba.org>
Mon, 4 Jul 2005 15:42:08 +0000 (15:42 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:19:13 +0000 (13:19 -0500)
commit0eee17941595e9842a264bf89ac73ca66cea7ed5
treeb34521c69c68b583fbb6c1de611b12441fb0da89
parent5fcaa21d67e399aab4af15f4f6f919203c1152e5
r8148: - make the PAC generation code a bit more readable and add some outof memory checks

- move to handmodified pull/push code for PAC_BUFFER
  to get the _ndr_size field and the subcontext size right

- after looking closely to the sample w2k3 PAC in our torture test (and some more in my archive)
  I found out that the first uint32 before the netr_SamInfo3 was also a pointer,
  (and we passed a NULL pointer there before, so I think that was the reason why the windows clients doesn't want our PAC)

  w2k3 uses this for unique pointers:

  ptr = ndr->ptr_count * 4;
  ptr |= 0x00020000;
  ndr->ptr_count;

- do one more pull/push round with the sample PAC

metze
source/auth/kerberos/kerberos_pac.c
source/include/structs.h
source/librpc/config.mk
source/librpc/idl/krb5pac.idl
source/librpc/ndr/libndr.h
source/librpc/ndr/ndr_krb5pac.c [new file with mode: 0644]
source/torture/auth/pac.c