Need guide for hacking Samba NT to understand AFS

Johan Hedin johanh at
Wed Dec 1 09:39:56 GMT 1999

I need some guidance for a making Samba PDC understand AFS. I want to
store the user key files on the local disk of the Samba server. I know
this is not the best solution. Better solutions have been proposed by
Allan Bjorklund, but I need something quick and dirty now. We mainly
use Sun machines at our site and have only a few NT boxes. What I want to
do is to read the key file as the user after the encrypted password is
validated. I will also implement a alarm() call to renew the ticket. My
questions are:

* I need a hint of where to put this AFS login, i.e. where do put the
  routine that reads a file as a user after the forking and encrypted
  password validation is done.

* How do I get the userid and user name (in order to prevent users
  from reading somebodys else key by symlinking to it). I imagine
  I need something like

  set_uid_to_user(...)  /* How do I write this */
  read_AFS_key_file(username) /* This I will write */
  set_uid_back_to_root() /* How do I write this */

If everything works, I will submit my patches to the samba team.


Johan Hedin

| Johan Hedin                      | johanh at             |
| Ph.D. Student and System Manager | |

More information about the samba-ntdom mailing list