Network questions
Network questions
Hello!
Does anybody know the answers on this two questions:
1. How can I get my current login in Novell Netware ( something like function WNetGetUser() for Win )
2. Function GetIP() on my PC returns "0.0.0.0", but I have the static IP in my XP system. What I do wrong?
Thank's a lot.
Does anybody know the answers on this two questions:
1. How can I get my current login in Novell Netware ( something like function WNetGetUser() for Win )
2. Function GetIP() on my PC returns "0.0.0.0", but I have the static IP in my XP system. What I do wrong?
Thank's a lot.
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Re: Network questions
Did you try the command "WhoAmi"1. How can I get my current login in Novell Netware ( something like function WNetGetUser() for Win )
Regards
Anser
Re: Network questions
Hello, Anser!
Thank you, but I can't find the command "WhoAmi" in FWH, xHarbour or OS Windows and Novell NetWare
May be it's only for Linux...
Have you some example of usage this command?
Thank you, but I can't find the command "WhoAmi" in FWH, xHarbour or OS Windows and Novell NetWare
May be it's only for Linux...
Have you some example of usage this command?
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Re: Network questions
Try netname( .t. )
Re: Network questions
Thank's. But "netname" is return the name of current Windows User...Try netname( .t. )
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Re: Network questions
Wouldn't the user name be the same? If you are not using the integrated log in then how about netbios.sys. Novell NetWare Requester provides a NetBIOS driver (NETBIOS.SYS) that emulates the NetBIOS protocol so netname( .t. ) should return correct network name.
- Rick Lipkin
- Posts: 2397
- Joined: Fri Oct 07, 2005 1:50 pm
- Location: Columbia, South Carolina USA
Re: Network questions
WnetGetUser() has always worked for me in both Novell and Microsoft networks .. NetName(.t.) works as well
Rick Lipkin
Rick Lipkin
-
- Posts: 824
- Joined: Thu Oct 13, 2005 7:39 am
- Location: Germany
Re: Network questions
Hello,
For clipper there was a lib called "netto", which has all functions especially for novell. It should be possible to adapt the functions to xHarbour. If you are interested, I can send it to you.Loach wrote: Does anybody know the answers on this two questions:
1. How can I get my current login in Novell Netware ( something like function WNetGetUser() for Win )
kind regards
Stefan
Stefan
Re: Network questions
Hi!
In our network (more than 500 pc) each user have the unique Novell name, but in OS Windows everybody have only "Admin" and "User" records. Than, if you have the same passwords (in Novell and Windows) after the Novell password inputing, Windows registration comes automaticly.Wouldn't the user name be the same
In my case WnetGetUser() and NetName(.t.) returns "User" instead of my Novell name...WnetGetUser() has always worked for me in both Novell and Microsoft networks .. NetName(.t.) works as well
Thank you so much! If it's possible, send it on Loach(at)mail.ru.For clipper there was a lib called "netto", which has all functions especially for novell. It should be possible to adapt the functions to xHarbour. If you are interested, I can send it to you.
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Re: Network questions
Netname() requires netbios to be turned on. You have to have either have NETBIOS.SYS for Netware Requester or in Windows have netbeui turned on.
Re: Network questions
I have NETBIOS.SYS in windows\system32\driversYou have to have either have NETBIOS.SYS for Netware Requester
in Windows have netbeui turned on.
Do you mean this flag in network connection properties?
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Re: Network questions
Sorry it has been a while since we moved from Netware. I would have to do some more checking to find out why the netname() function is not working right. Here is another idea, I remember the Netware login script used to set an evironment variable "UserName". Click "Start" then "Run" and enter "cmd" in box and press enter. Type "Set" into cmd window and press enter. You should see one of them have the user name. Then use gete("User Name Var").
- Rick Lipkin
- Posts: 2397
- Joined: Fri Oct 07, 2005 1:50 pm
- Location: Columbia, South Carolina USA
Re: Network questions
There is a netware 3rd party 'legacy' clipper and 32 bit .dll from Blinker ( blinkink.com ) called 'NovLib' .. it is specifically for Novell networks. It is a legacy product and did work 'somewhat' in a NDS\eDir environment. When Novell went away from the 3x environment to 4x and beyond .. we found syncronizing the user profile ( desktop ) using ( novell ) Zenworks ( dynamic local user ) solved all the problems .. that way WNetGetUser() would work because the user profile and the user login were the same.
Rick
Rick
Re: Network questions
Great idea!!! I even didn't think about it!!! It's all work well. There are two the same variables I need: NWUSERNAME and USERLOGINNAME.the Netware login script used to set an evironment variable "UserName"
Also I found it in Windows register: HKEY_CURRENT_USER\Volatile Environment.
So, many thank's for everybody!!!
Best regards!
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
Sergey (Loach) Abelev
fwh 9.04/xHarbour 1.2.1 (Rev. 6406)/Bcc55
- Rick Lipkin
- Posts: 2397
- Joined: Fri Oct 07, 2005 1:50 pm
- Location: Columbia, South Carolina USA
Re: Network questions
Loach
I work for a VERY large State Agency ( over 5000 users and desktops ) and we used to be a Novell shop .. When I used Novlib to interogate the Novell environment it was very specific to Novell .. and guess what .. we changed from Novell to Microsoft .. which made all the Novell specific libraries useless.
Just be mindfull that 'best practice' for any network ( I am also a network admin for 400 local people ) is to have the users profile made the same as the network id .. I just can not imagine why such a 500 user customer like yours would chose to sync a desktop the local Admin .. very dangerious and a lazy practice .. If they are a Novell shop they need to be using zenworks to manage their desktops with dynamic local user enforced .. that way ( like microsoft ) when anyone logs into a worstation .. their profile is created ( dynamically ) on the local box to match their login username on the network ..
Then WNetGetUser() will work in both network environments .. and you don't have to do anything special .. no environmental variables or special network specific software.
Just my 2 cents there .. I realize you are not in any position to make suggestions to your customer.
Rick Lipkin
I work for a VERY large State Agency ( over 5000 users and desktops ) and we used to be a Novell shop .. When I used Novlib to interogate the Novell environment it was very specific to Novell .. and guess what .. we changed from Novell to Microsoft .. which made all the Novell specific libraries useless.
Just be mindfull that 'best practice' for any network ( I am also a network admin for 400 local people ) is to have the users profile made the same as the network id .. I just can not imagine why such a 500 user customer like yours would chose to sync a desktop the local Admin .. very dangerious and a lazy practice .. If they are a Novell shop they need to be using zenworks to manage their desktops with dynamic local user enforced .. that way ( like microsoft ) when anyone logs into a worstation .. their profile is created ( dynamically ) on the local box to match their login username on the network ..
Then WNetGetUser() will work in both network environments .. and you don't have to do anything special .. no environmental variables or special network specific software.
Just my 2 cents there .. I realize you are not in any position to make suggestions to your customer.
Rick Lipkin