I was e-mailed about this thread, and it is similar to one I posted back in February. Like Robb, I was trying to determine the username on a remote workstation. I've used mod_ntlm and it works fine for authentication, but that isn't actually the objective here.
As I understand it, the way mod_ntlm basically works is to pass the SID information from a remote workstation to a PDC/BDC, which does the decryption and authentication of the SID contents. The PDC/BDC then returns a result code to mod_ntlm, and based on that result code the user is either granted or denied access to the requested resource. So mod_ntlm never actually sees a plaintext username. 8(
We tried doing some funky stuff with uudecode to get the username out of the data that mod_ntlm hands off, and got to where we could actually see it most of the time. It was a pretty wild hack that we didn't want to put in a production environment, though, especially since it wasn't 100% reliable.
Having said all this, there could be something I've missed. So if anyone has found a way to obtain the username on a remote NT4/W2K machine and put it into a PHP variable (on a Unix/Apache server, mind you!), I'd love to hear about it. Thanks!
--Andy