[jcifs] a question concerning the calling hostname forauthentification

Michael B Allen mba2000 at ioplex.com
Sat Oct 11 09:53:17 EST 2003

> But it works not correctly, because in the domaincontroller the users are
> registred with the "userWorkstations" option, so that they can only
> authenticate from the workstation they are registered to.
> We have found a configuration option in the jcifs package, the property
> "jcifs.netbios.hostname", that can be set to a workstation hostname, so
> that
> the server uses this name as the calling hostname when authenticate at the
> server.

So the server compares the hostname submitted during the NETLOGON with the
CallingName provided by jCIFS which is something like JCIFS32_129_E5 which
of course doesn't match.

> But this property can only be set once at the start of the
> application.
> But we have the need to dynamically set this "calling hostname" for every
> user authentification. As far as we understood the sources, the
> "jcifs.netbios.hostname" property is evaluated in the class NbtAdress in a
> static procedure. So that is the reason, why it is only evaluated once.

Well jCIFS only submits the CallingName when the session to the domain
controller is established so you would have to open a separate connection
for each user.

Unfortunately I don't think you're going to get this to work. The proper
way to fix this is to implement the NETLOGON procedure in which case the
hostname will be whatever we prefer. This is on The List but it's not
going to happen very soon.


A program should be written to  model the concepts of the task it
performs rather than the physical world or a process because this
maximizes the  potential for it  to be applied  to tasks that are
conceptually similar and, more  important, to tasks that have not
yet been conceived.

More information about the jcifs mailing list