473,394 Members | 1,935 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

how to get domain name of a remote computer

We need to resolve with which computer my computer is communicating. We
write a sniffer that gets pakets and so we resolve ip addresses and now we
need to get their domain names.
I think we need to use netbios protocol but I dont know how. How can we do
this ...
Nov 16 '05 #1
1 11688
Hakki,

Are you referring to the DNS name of a machine, or are you referring to
the windows domain name on a local intranet?

If the case is the latter, then you can call the static GetHostByAddress
method on the Dns class in the System.Net namespace.

If it is the former, then you might have to call the gethostbyaddr
function in the WinSock 2 library in order to get this (as it can return an
NETBIOS name). From there, you should have no problem getting the domain
name.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Hakki" <hy*****@stx.cs.deu.edu.tr> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
We need to resolve with which computer my computer is communicating. We
write a sniffer that gets pakets and so we resolve ip addresses and now we
need to get their domain names.
I think we need to use netbios protocol but I dont know how. How can we do
this ...

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Martin Robins | last post by:
I need to access the scheduler service on a network computer in order to manipulate it remotely from .NET; I have all of the necessary code to perform the manipulation and it works - great - but I am...
5
by: Rocky | last post by:
Hi, I have a webform, with 2 textboxs and a submit button. In the text box1, i enter a username and in textbox2 I enter the computer name. Both the username and computer name is in active...
6
by: Anders K. Olsen | last post by:
Hello group I'm trying to list the users and groups who has read access to a file. I use .NET 2.0 and FileInfo.GetAccessControl().GetAccessRules(...) and then loop through the...
6
by: Spyder | last post by:
When you go to "MyComputer" and get properties and select "Computer Name", you get the Domain or Workgroup a computer belongs to. I have looked thru MSDN library, the Internet, the Registry and in...
10
by: Sridhar | last post by:
HI, I am having problems setting up a website so that it will be available only inside the domain. We have three servers. One is iis server and second one is internal server and the third one is...
0
by: Vivek | last post by:
Because of the increased security concerns of the network admin, i no longer am the admin on my development machine. To work around this and have a secure environment, I have virtual pc 2004 ...
4
by: JB | last post by:
I am trying to get a list of all the active computers running on my domain. I'm writing some remote management style software with WMI, which works fine when i know the computer name, but i just...
0
by: SysProfile | last post by:
Hi people, I'm currently trying get the name of my Primary Domain (Windows 2003 Server) and the proper name, from a remote computer. This is an example domain: mydomain.com computer name:...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.