networking

Why did Microsoft implement sockets differently?

I'm currently in the middle of a project involving sockets, and I just use Linux's sys/socket.h file. Cue the port to Microsoft, and realizing that Winsock is different. I guess I have two questions. First, what're the main differences between the two implementations? Is there an easy way to "translate" them? A link to a guide would be ...

How can a C# app easily communicate and transfer files on a network?

How can a C# app easily communicate with an instance of itself present on another computer, which is on the same network, and transfer files and data? Assuming the computers on the network have fixed local IP addresses, and they each know each others IPs. Would there also be a way to communicate if the IPs are unknown? based on some dis...

Ramaze Routing Broken Behind a Proxy

I need to test my application with outside services, so (like I usually do in this situation) I've set up an Apache proxy to forward requests on a custom domain to my laptop inside the network (laptop.mydomain.com:80 => 192.168.1.3:3000). This always worked fine with Rails, but it seems to break Ramaze for some reason. Any request coming...

I/O Signals and Handlers

I want to designate a callback for UDP port such that every time a new packet arrives, a handler is called for it. I know about using fcntl() to cause file descriptors to raise SIGIO, but let's say things aren't quite that simple. I have an object A with socket a and an object B with socket b. Socket a receives a new packet, and the...

HTTP proxy connection sharing

I am attempting to implement an HTTP tunnel using similar techniques to those employed by web browsers to simulate a full-duplex connection, in Java using the Netty framework. I wish to implement this in such a way that it will work in the presence of real world HTTP proxies. I am attempting to do this without using a servlet container, ...

How should I go about implementing this SMS notification system?

Hi, I have developed a application which involves billing users. To do this i have incorporated a GSM modem (gateway) that the SMS messages are sent through. This SMS message is sent to the user when he is billed with the bill details. The GSM modem is connected to a single computer but the billing can happen in other systems. How do I s...

Android - Unknown Error when trying to use networking

Hey, I've just started developing Android applications. I'm having a little problem with networking. If I run the following code I get an "unknown error" exception message: import org.apache.http.impl.client.DefaultHttpClient; import org.apache.http.client.ClientProtocolException; import.org.apache.http.client.methods.HttpGet; import...

WMI EnableDHCP fails on disconnected adapter

I'm using the WMI Win32_NetworkAdapterConfiguration Class EnableDHCP Method to enable the DHCP service on a network adapter. I'm using XP Embedded with SP2 but it also happens on my desktop (XP SP3). Everything works great except when the network cable is unplugged. If the cable is disconnected, EnableDHCP returns 94 (Path, file, or o...

monitor traffic to and from my pc

I want to see each url request made my by browser. I want to see the url requests made by ajax. Which software should I use? Some java code would also help. ...

Send HTTP request as fast as possible

In order to test my program, I want to send about 50 http requests as fast as possile. Currently I'm using bash script which calls curl & to send each request like curl "http://my.host.com/test.php?param=1" & curl "http://my.host.com/test.php?param=2" & curl "http://my.host.com/test.php?param=100" & but it seems not fast enough. I gue...

Why does NSNetServiceBrowser find unpublished services in iPhone OS?

Hey everyone, Building a desktop version of my mobile app and providing the user syncing over wifi. Everything works great in the simulator - no problems resolving net services (which are published by the desktop app) or noticing when services become unavailable. The problem is when I run the app on the phone services are discovered an...

How do i allow the HttpListener in vb2005.net to allow outside access?

How do i allow the HttpListener in vb2005.net to allow outside access? For testing purposes i have set it up to use the same ports as my webserver uses so there are no firewall issues. the prefixes are set up to take the localhost on port 80 the realm is unset AuthenticationSchemes = Net.AuthenticationSchemes.Anonymous it works just ...

GetHostByAddr() win32

Hi All, I am giving an IP Address : 64.78.58.91 and i would like to retrieve the hostname using GetHostByAddr() win32 API. Instead of returning www.ripcode.com it returns intermedia.net I would expect to get www.ripcode.com Can you suggest a Different API which could solve this problem. Thanks in Advance Best Regards, Suren ...

How to tell with Objective-C if the iPhone is connected to a wifi network?

Hi, In the context of an Objective-C, iPhone application, I need to be able to tell whether the iPhone is connected to a wifi network, and if possible listen to changes in this state. Does anyone know how to do this? thanks, gabouy ...

Network Programmer Blogs (especially for games)

What are some good network programmer blogs? I'm especially interested in people who write about multiplayer games (MMORPG/RTS/FPS/etc), but any well written blog on the subject would be great. Here's a good blog I found on another stackoverflow post: Glenn Fiedler's Networking for Game Programmers Gamasutra Blogs occasionally has arti...

MS Access FE/BE multiple Tables Multiple links

I have a large complex multiple table in one database that customers use with a FE/BE link over some LAN networks which occasional corrupt the database I was wondering if grouping the tables into separate multiple databases and using separate links would help limit the damage? Note: I have no control over customers network quality and ...

How to find connected hosts at network (vpn or lan)

Hello, I'm looking for possible solutions to the following need: I have a VPN configured (using openVPN over Linux, BTW), and I want to know at any moment which hosts are connected to it. I recognize that it probably is the same thing as trying to know which hosts are connected to a lan, so any of the solutions might do the job... The ...

Python urllib2 problem?

I installed Python 2.6.2 earlier on a Windows XP machine and run the following code: import urllib2<br> import urllib<br><br> page = urllib2.Request('http://www.python.org/fish.html')&lt;br&gt; urllib2.urlopen( page )<br><br> I get the following error. Traceback (most recent call last):<br> File "C:\Python26\test3.py", line 6, in <...

How to find IP-Address ranges from list of IP addresses

I have around 20000 IP Addresses. and I am looking to find the network-block-ranges for these IP addresses. The purpose is to provide information to have hole in the firewall so that these addresses can be allowed. I can looking in a.b.c.d/x bits format. There could be several ranges. Update: I have IP Addresses already in my apache log...

php 5 $_SERVER['SERVER_ADDR'] with multiple IPs

I'm running an ubuntu jaunty server with 2 network interfaces configured: one public IP, one private. When I request the server IP I get the public IP. If I've got multiple interfaces is there a best practice for assuring I'm getting the public one (which is what I want)? <?php echo " <table>"; echo "<tr><td>" .$_SERVER['SERVER_ADDR']...