Questions tagged [networking]

Networking is associated with creating and managing networks as well as adding network connectivity to a (set of) programs.

Filter by
Sorted by
Tagged with
2
votes
1answer
545 views

TCP Packet design

I'm implementing a client/server app using JSON (as String) via TCP/IP. String --> Packet --> byte[] --> tcp/ip --> byte[] --> Packet --> String ...
3
votes
2answers
9k views

HTTP request parser in C

I'm implementing a simple HTTP server in C, and this is the first part of it. Basically, it takes a string containing a "raw" HTTP request, and parse it into a ...
5
votes
1answer
101 views

Python program that checks connections based on URLLIB response

The main function tries to create a urllib connection, and if it fails/succeeds the label changes accordingly. However, I'm looking for ways to improve this code. Some elements I'm already aware of: ...
5
votes
2answers
394 views

Python program that pings and outputs a response in Tkinter

I have a program that allows me to check (in a nicer way than using command prompt) what my ping will be when playing League Of Legends. I've implemented all of the elements that I had hoped, however ...
2
votes
1answer
77 views

Crap (from the Past) Scraper

I listen to a podcast called Crap from the Past. It's a radio show that airs weekly in Minneapolis and specializes in playing music from my childhood. The show has been on the air for ~26 years. I ...
1
vote
1answer
372 views

Class for TcpClient usage

I have created a class which wraps the TcpClient. It's greatly simplified everything when developing. It takes an interface for me to run callbacks where I can ...
3
votes
2answers
579 views

Networking library for c++, windows

I have planned to implement a networking library for C++ which is specific to windows since I can't find a library for my needs. Here is an implementation of TCP server using this library. First of ...
4
votes
0answers
687 views

Python port scanner using multithreading

I have written a rather simple port scanner using python and I would like to know things I could do better regarding: Code quality, making the code in general better Performance, making the code run ...
4
votes
1answer
67 views

Java - Downloading Wikipedia Articles

This is my first experiment that uses a network API and connects to the internet. I tried to write a program that gives you an article of wikipedia directly by typing the name. You can get an ...
4
votes
1answer
74 views

Restart network-manager service if connection down on wake shell script

I use Ubuntu (Trusty and Xenial) and usually put my computer in sleep mode rather than power it down. A common problem is that upon wake the network is down so one has to restart the network-manager ...
1
vote
1answer
2k views

Multi-client TCP server with a thread for each client and DB connection pool

I'm creating a Qt TCP (with SSL) server to which multiple clients should connect and use the DB, and this is the main task. So, I think I can use this architecture: each client has its own thread, and ...
1
vote
0answers
47 views

Queuing outgoing packets to fix server lag issues

I have been developing a game lately, my first multiplayer game. I am using Netty and LibGDX. So previously, before this update I added, I was only queuing incoming packets, I had to do this because ...
2
votes
1answer
169 views

Executing a command using Net::SSH

According to the local cop (rubocop), my method has too many lines. ...
3
votes
2answers
424 views

Arp-spoof check in PowerShell

To learn some PowerShell I made a tool, I've made before in bash. It pings the subnet for arp values and checks if there is no weird behaviour. ...
4
votes
1answer
55 views

Transferring many Vector3 across network ten times per second

I am making a game with C#/Unity, and have devised a Client-Server system to update the positions and directions of all units in play ten times a second. My biggest concern is that the more units ...
3
votes
1answer
62 views

Don't MiTM me please

To first understand how MiTM works I've made a few MiTM scripts, but this time I wanted to defend myself against such attacks. I'm unsure if my idea even works. The code seems to be working but I make ...
2
votes
0answers
474 views

Python scapy subnet mapper

This a follow-up question of Python scapy - TCP port scan of subnet I've decided to make an all powerful subnet mapper in Scapy to better understand how tools like ...
4
votes
1answer
1k views

Python scapy - TCP port scan of subnet

Question I love using NMAP and other related tools to scan networks really fast. But using a tool and understanding how it works are 2 different things, thus I tried creating a program where I can ...
1
vote
0answers
143 views

Converting Cisco IOS output to XML

The INPUT FILE is created by a script that runs "show interface description | i FN" against each of my routers. Once I have that file, my PYTHON SCRIPT below, parses the INPUT FILE for each of the ...
3
votes
0answers
5k views

OpenSSL Client/Server

I have recently begun to dabble with OpenSSL to provide TLS encryption to TCP socket communication. Through documentation and heavy reference on example code I have come up with the following code (...
12
votes
2answers
3k views

Bob Marley is jamming on the wifi

Bob is jamming it's way through the city deauthenticating people from thier wifi for a few seconds. First scanning all possible wifi-AP and then pretty printing them, afterwards you can choose a wifi ...
6
votes
2answers
239 views

Multiplayer Peer-To-Peer position interpolation

I have coded this movement interpolation for Unity3d using Photon. OnPhotonSerializeView gets called at the tickrate. Any kind of criticism/improvement suggestions are welcome. I tried to make the ...
2
votes
3answers
1k views

Reading data from network stream

I have a function to request an update from the server. I provide the query and also indicate the expected length of the response. ...
3
votes
0answers
73 views

Retrieving a certain amount of data from a socket [closed]

I'm trying to retrieve a certain amount of data from a socket, both Unix domain and TCP, but I've no control over its format or length. I discussed this with someone who told me to set my receiving ...
1
vote
0answers
994 views

Protocol to parse packets using TCP

I posted this question a year ago and until a weeks ago I solved most of the issues that were happening due to incomplete packets, things like trying to read the packet header again when the payload ...
8
votes
3answers
401 views

Update MediaWiki settings with dynamic IP address

I'm running a MediaWiki instance from a home server where the public IP address is not guaranteed to remain static. The following script is meant to run at boot time to check if the IP address has ...
2
votes
1answer
1k views

Be the Man in the middle, and (ARP) Poison your network

Whilst learning from a Python Networking book, I've made this tool to perform a Man in the Middle attack by ARP-Spoofing on a Network. I think this has been done plenty before. ...
3
votes
0answers
189 views

WebRTC data channel connection establishment with separate offerer and answerer roles

I've developed a demo application for demonstrating connection establishment using WebRTC data channels. I am using cross-window communication using postMessage for ...
4
votes
2answers
3k views

Python proxy checker/scanner

Here is my attempt at a simple HTTP proxy scanner/checker. I've been learning python for about 6 months now and decided to move beyond simple scripts and data scrapers. I think the code looks messy ...
13
votes
1answer
292 views

Game-oriented UDP protocol

As part of a small multiplayer game project I designed a generic (and not too complex) protocol (used over udp). The game is 2D, has physics-based elements (e.g. rigid body, smoke) and should be ...
63
votes
4answers
10k views

Send a tweet to ISP when internet speed drops

I have written an app in Python 3 which monitors internet speed and will send a tweet to an ISP when the speed drops too low. The app has a config file where the ISP and target speeds can be ...
4
votes
1answer
357 views

Flexible TCP socket framework

I'm working on a flexible socket framework and trying to polish it so it's actually something usable in further development. Would really appreciate any critique, also I’m really interested whether I'...
1
vote
0answers
253 views

Thread-safe IDisposable Tcp Connection Manager

I'm trying to implement a thread-safe Connection Manager. I've split my class in two files, one with TraceMessages and another with the actual implementation. I'm just going to post the file with the ...
3
votes
1answer
175 views

Get external IP and update ddns service

I've created a cli application that consists of a package with 2 functions. One to get the external ip address, and another function to update a dynamic dns record at dns.he.net. Both are then used in ...
3
votes
1answer
8k views

Multithreaded C# TCP Socket Server

I am trying to write a simple TCP server in C#. It needs to be able to receive packets and do work on them. Ideally it will only be receiving packets from a single computer, but I'm making it able to ...
3
votes
2answers
755 views

Cisco router configuration script generator in Java

I've written a basic program to generate a script that will automatically configure routing in a Cisco router. It reads an input file which contains the directly connected interfaces of a router. e....
6
votes
1answer
348 views

Flexible socket framework

I'm working on an async socket server, would really appreciate any critique and some advices regarding the place where i process received messages. My interfaces are as follows: IAsyncClient <...
1
vote
1answer
724 views

Multithreaded telnet chat server in Java

I have writed a multithreaded telnet chat application in Java. In main method I run telnet server. In server class at run method I bind in specified port (8189) and I spawn listener threads for every ...
2
votes
1answer
102 views

Caching strategy

I was making a simple currency converter utility and had to cache the conversion factors after fetching from server. Came up with the below interface. I have basically delegated the caching ...
6
votes
1answer
1k views

SFML-based chat in C++

I wanted to get some review on this code I wrote. The repo is here if you want to download the CodeBlocks project. This program is several things: it is a console using SFML graphics; it is a console ...
7
votes
1answer
1k views

Real time UDP packet decoder

I have basic C++ lectures at a university and I don't really know how I can optimize this line of code for a real-time application (I call this function every 5 ms for UDP packet decoding). I would ...
1
vote
1answer
2k views

Forced and easy hton/ntoh conversion

Context: When sending message across the network, the sender has to convert the message from host byte order to network byte order and the receiver has to do the the reverse - network order to host ...
1
vote
1answer
4k views

IP Scanner via python sockets

Please review my code for scanning active IP address . Please Suggest improvements ... ...
2
votes
0answers
1k views

Folder sharing with python sockets

I am just getting started with python. I wanted to make a folder transfer tool to get familiar with python sockets. ...
7
votes
1answer
87 views

A simple PyPI crawler

I had to make a program to crawl through a bunch of PyPI packages and see how many of them implement custom compare operators (i.e. grep for def __le__ etc). After ...
23
votes
2answers
5k views

Simple and effective port checker in C++

Intro A couple of weeks ago I finished a Python implementation of a multithreaded port checker and I wasn't quite happy with the result I've got (speed). I needed it to be faster, so I've built ...
3
votes
0answers
79 views

Flexible port scanner library

I have tried to generalize the concept of turning an IP address into a boolean. The save format is an overly complicated way of storing consecutive IP addresses as strings of bits Example usage: <...
5
votes
3answers
1k views

Interface design to have multiple implementations of network call libraries (Retrofit or Volley)

I am learning design patterns from Head First Design Patterns and a principle I came across is to "code to interface". Now I want to apply this principle in my Android app, which includes lots of API ...
4
votes
1answer
8k views

C multithreaded chat client and server

I've written a TCP chat application for the command line that supports multithreading. I'm wondering whether I'm using best practices for socket programming, what other types of functionality would ...
0
votes
1answer
2k views

Winsock recv all bytes

I had some issues with sending huge data and receiving them with Winsock so I made some improvements on my RecvAllBytes function and the same with ...