network

c# network login

How do I perform a network login, to access a shared driver for instance, programmatically in c#? The same can be achieved by either attempting to open a share through the explorer, or by the net use shell command. ...

In PowerShell, how can I determine the root of a drive (supposing it's a networked drive)

In PowerShell, even if it's possible to know if a drive is a network drive: see http://stackoverflow.com/questions/158359/in-powershell-how-can-i-determine-if-the-current-drive-is-a-networked-drive-or When I try to get the "root" of the drive, I get back the drive letter. The setup: MS-Dos "net use" shows that H: is really a mapped net...

Binding a socket to port 80 in ansi c

When I try to bind port 80 to a socket in c, i always get the error, that I don't have permission to use this port. is there an easy way to get this permission? ...

how to disable/enable network connection in c#

Basically I'm running some performance tests and don't wan't external network to be the drag factor. I'm looking into ways of disabling network LAN. What is effective way of doing it programmatically? I'm interested in c#. If anyone has code snippet that can drive the point home that would be cool. ...

Using Linux, how to specify which ethernet interface data is transmitted on

I'm working on a Linux based server system in which there are two network interfaces, both on the same subnet (for now, lets just say they are 172.17.32.10 & 172.17.32.11). When I send data to a host on the network, I would like to specify which interface on my server the data is transmitted on. I need to be able to switch from one int...

Writing a reliable, totally-ordered multicast system in Python

I have to write a reliable, totally-ordered multicast system from scratch in Python. I can't use any external libraries. I'm allowed to use a central sequencer. There seems to be two immediate approaches: write an efficient system, attaching a unique id to each multicasted message, having the sequencer multicast sequence numbers for ...

Determining when an EDGE connection comes back after a dropout on an iPhone

I've incorporated Apple's Reachability sample into my own project so I know whether or not I have a network connection - if I don't have a network connection, I don't bother sending out and requests. I decided to go with the status notification implementation because it seemed easier to have the reachablity updated in the background and ...

Best way to simulate a WAN network

Simplified, I have an application where data is intended to flow over the internet between two servers. Ideally, I'd like to test at what point the software ceases to function. At what lowerbound limit (bandwidth, latency, dropped packets) do things stop working to test the reliability of the software. What I thought I would do was the ...

.NET SqlConnection NIC usage

Having a computer with multiple NICs, I need to specify somehow the one to use for the connection to SQL Server. ...

Command/Powershell script to reset a network adapter

OS: Vista enterprise When i switch between my home and office network, i always face issues with getting connected to the network. Almost always I have to use the diagnostic service in 'Network and sharing center' and the problem gets solved when i use the reset network adapter option. This takes a lot of time (3-4 min) and so i was tr...

Enumerating network shared directories in C++ / MFC

I need to get a list of directories shared by the current computer, and their shared names. How do I do this in C++ / MFC? ...

Is it possible to programatically find out what process is locking a file across a network

I have a file on a Windows 2003 server which is locked by a process running on another Windows 2003 server. Is it possible to find out which process on which machine is locking this resource. I don't mind which language I use to do this. ...

Linux / C++: Get the IP Address of local computer

This Question is almost the same as the previously asked Get the IP Address of local computer-Question. However I need to find the IP address(es) of a Linux Machine. So: How do I - programmatically in C++ - detect the IP addresses of the linux server my application is running on. The servers will have at least two IP addresses and I nee...

A good Java library for network math

I'm looking for a Java library that is geared towards network math and already tested. Nothing particularly fancy, just something to hold ips and subnets, and do things like print a subnet mask or calculate whether an IP is within a given subnet. Should I roll my own, or is there already a robust library for this? ...

Only allow one server to access a file on a network drive

I have an application running on multiple IIS servers that need to parse a CSV file that is placed on a common network drive. If I use the System.IO.FileSystemWatcher Created event to be notified of the event when the file is available, how can I ensure only one server parses the file? If all servers are notified of this change, all wi...

How can I access netstat-like Ethernet statistics from a Windows program

Hi, How can I access Ethernet statistics from C/C++ code like netstat -e? Interface Statistics Received Sent Bytes 21010071 15425579 Unicast packets 95512 94166 Non-unicast packets 12510 7 Discards 0 ...

Multicast Join on Linux and IGMPv3

We've run into a thorny problem. We are writing a c++ program that receives multicast UDP traffic. We're in the process of moving our applications to a different network environment and our operations team has requested that we support IGMPv3 membership announcements from our applications. Initial investigations indicate that Linux 2....

What's the best way to sync large amounts of data around the world?

I have a great deal of data to keep synchronized over 4 or 5 sites around the world, around half a terabyte at each site. This changes (either adds or changes) by around 1.4 Gigabytes per day, and the data can change at any of the four sites. A large percentage (30%) of the data is duplicate packages (Perhaps packaged-up JDKs), so the s...

SNMP payload address translation

I'm using iptables under linux to NAT SNMP traffic. Some of the SNMP packets have VARBINDs that contain the (real) IP addresses of the devices that generated them. This confuses standard management tools, which need to see the NATted addresses in the VARBINDs. So I need to translate the addresses in the payload in addition to those in...

What's a good tool to monitor network activity

I'm operating a neighbourhood WIFI network in a rural environment. Now I'm looking fo a monitoring tool to run on a server (Windows or Linux) wich tracks bandwidth, uptime (clients as well as internet connection), et al. Most of this information is exposed via SNMP by my routers and access points, so SNMP support is required. Additiona...