GSS Example Read Me

You will need a few things set up to run the sample:

	a KDC (the one that comes with Mac OS X Server is easy to set up)
	an edu.mit.Kerberos configuration file for your KDC's realm on the client machine

Note that the client and server can be the same physical machine.

Steps (assuming a MIT kdc setup):

1) Open a terminal window on the server machine and become root.

	sudo -s

2) Launch kadmin.

	kadmin -r EXAMPLE.COM

3) Create the client principal for your user (eg: testuser@EXAMPLE.COM):

	add_principal testuser@EXAMPLE.COM

4) Create the service principal for your test service (eg: test/server.example.com@EXAMPLE.COM):

	add_principal -randkey test/server.example.com@EXAMPLE.COM

5) Export the keys for test service to the server's local keytab:

	ktadd test/server.example.com@EXAMPLE.COM

6) Quit kadmin.

7) Start the server on an unused port:

	GSSExampleServer --port 8000 --service test

8) Open a terminal window on the client machine as a normal user.

9) Get the client user's TGT:

	kinit -p testuser@EXAMPLE.COM

10) Run the client:

	GSSExampleClient --server server.example.com --port 8000 \
            --sprinc test/server.example.com@EXAMPLE.COM       \
            --cprinc testuser@EXAMPLE.COM

Note that the '--cprinc testuser@EXAMPLE.COM' argument is optional and only necessary if the tickets for testuser@EXAMPLE.COM are not in the default ccache.