networking

using pyunit on a network thread

I am tasked with writing unit tests for a suite of networked software written in python. Writing units for message builders and other static methods is very simple, but I've hit a wall when it comes to writing a tests for network looped threads. For example: The server it connects to could be on any port, and I want to be able to test t...

Specify source IP address for TCP socket when using Linux network device aliases

For some specific networking tests, I've created a VLAN device, eth1.900, and a couple of aliases, eth1.900:1 and eth1.900.2. eth1.900 Link encap:Ethernet HWaddr 00:18:E7:17:2F:13 inet addr:1.0.1.120 Bcast:1.0.1.255 Mask:255.255.255.0 eth1.900:1 Link encap:Ethernet HWaddr 00:18:E7:17:2F:13 inet...

the best resources to get involved in p2p file sharing project

these days I'm interested to join an open source p2p file sharing project. my knowledge about the topic is not so specific, I mean I know things about security, networking, p2p basics but I still feel lost as to where to begin to get the big picture and practical details in the same time. in short what are the recommended resources? righ...

QT & UDP-Socket

Hi, I have a question about QT & network sockets. If I have a computer with multiple IP-Adresses in different networks, how do I open an udp socket for a multicastgroup on a specific network-adapter/ip adress. eg: ip: 192.168.2.1 and 172.20.0.1 and I want to create a socket that receives packets from the multicast group 228.5.6.7 on th...

Spoofing the origination IP address of an HTTP request

This only needs to work on a single subnet and is not for malicious use. I have a load testing tool written in Python that basically blasts HTTP requests at a URL. I need to run performance tests against an IP-based load balancer, so the requests must come from a range of IP's. Most commercial performance tools provide this function...

Send iPhone HTTP request to Apache PHP webserver

I am programmer with a games and 3D graphics background and at the moment I would like to brush up on my networking and web development skills. I have a task that I would like to accomplish to do this. My idea is that I would like to be able to send a HTTP request or something similar to my webserver, which runs a LAMP based setup. I wo...

Direct P2P connection

This topic resembles this thread I'm rather new to the topic of network programming, never having done anything but basic TCP/UDP on a single local machine. Now I'm developing an application that will need P2P network support. More specifically I will need the application to connnect and communicate across the internet preferably withou...

Speed up my Java tcp transfer!

I need to speed up transfers across my gigabit ethernet connection. Right now, I'm doing something almost exactly like this, but I'm only seeing about 40% of that when I run this code below. I also ran this script on all of my (Mac Pro) machines before testing #!/bin/bash sudo sysctl -w net.inet.tcp.win_scale_factor=8 sudo sysctl -w ...

Is it possible to hook a packet after NF_IP_POST_ROUTING step of Netfilter?

I think that detection of source/destination mac addresses of a packet is done after NF_IP_POST_ROUTING step of Netfilter. Is it possible to hook the packet after this step with correct mac addrs? I want to decide about the out-going packet from my NIC to another to drop/accept packet. In another way, it is like to a firewall rule on mac...

How do I resolve an SRV record in Python?

Something which doesn't rely on native libraries would be even more better. ...

Checking if a directory exists on another server in ksh

I am trying to verify if a directory exists prior to moving a file in Korn, using the classic: if [[ -d ${dir} ]]; then scp file else exit 12 fi My Problem: That the directory is on another server, so whenever I check, the script can't find it and therefore fails and exits every time. My Question: Is ther...

Create a Windows (win32) service discoverable across the network

In short: How to reliably discover a server running somewhere on a (presumably multi-segmented) local area network with zero client configuration My client application has to locate the server application without knowing the server IP address. It has to work on a local LAN that may be split into segments with hubs or other switching dev...

Is there a HOSTS file on Symbian Series 60 5th Edition devices?

Hi, There used to be a HOSTS file on S60 3rd edition devices (see here). It was a great feature for QA. Anyone knows if there's such a file on S60 5th edition devices? Is there another way to tell the phone to go to a specific IP, given a host name? Many thanks, Ori ...

Why is UDP + a software reliable ordering system faster than TCP?

Some games today use a network system that transmits messages over UDP, and ensures that the messages are reliable and ordered. For example, RakNet is a popular game network engine. It uses only UDP for its connections, and has a whole system to ensure that packets can be reliable and ordered if you so choose. My basic question is, wha...

How does srv.sys decide on raw vs core mode depending on the underlying filesystem?

Hello, We are developing a file system for Windows using IFS Kit. We started to investigate a performance problem which caused our file system I/O to be much slower when shared over the network. After looking at it with FileMon and TCPView from Sysinternals we found out that if a NTFS/FAT was shared, the SMB client and server were trans...

how to block my site from one known IP address?

I want to block access of my site from one particular IP address, how can i do that.? using htaccess or ? ...

Flex Remote Service Verbose Mode?

Is there a way to display or log verbose communication DURING a remote service call with flex? In particular is there a way to get very detailed information about the service call while it is happening. Kind of like tracing HTTP headers from a command line. Basically, getting insight into the server transaction before the result or fault...

network monitoring on windows mobile 6

Hi there I am currently trying to write a network monitoring software for windows mobile 6. I googled a lot and some people say that it is not possible to use a NDIS driver or WinPcap or so for monitoring any network interface. Others say that it is possible. Fact is, that I found no exaples, nor any sourcecode on the net. Therefore I...

What is your favorite way of doing a MITM?

Hi Guys, Many of us must have done a Man-in-the-middle (MITM) attack on their internal networks- nothing serious, just for learning :) Now there are a number of protocol vulnerabilities which make MITM possible - ARP Poison Routing, STP Claiming Root Role dual home, HSRP active router... There are also a large number of network securi...

'ab' program freezes after lots of requests, why?

Whenever I use 'ab' to benchmark a web server, it will freeze for a while after having sent lots of requests, only to continue after 20 seconds or so. Consider the following HTTP server simulator, written in Ruby: require 'socket' RESPONSE = "HTTP/1.1 200 OK\r\n" + "Connection: close\r\n" + "\r\n" + "\...