23,775 questions
1
vote
1
answer
159
views
Packing multiple writes into single TCP packet
I have a sequence of send() calls to write bytes to a TCP socket. Is it possible to force the socket to only send TCP packets when they are either full (exceeding the MTU) or I explicitly indicate ...
0
votes
1
answer
156
views
Is it possible for two processes to deadlock on blocking send()/receive() calls due to both receive buffers being full?
Assume we have two clients talking to each other over TCP. Both are doing roughly the same thing:
recv(...) // Blocking receive call
do_work()
send(...) // Blocking send other client.
The way the ...
1
vote
0
answers
538
views
Rust panics with Os { code: 61, kind: ConnectionRefused, message: "Connection refused" }
Context
Hi. I’m quite new to Rust, and as I hope to gradually convert to being a fellow rustacean, I was ambitious (read: foolish) enough to retry a project (originally written in Go) I had last ...
0
votes
1
answer
324
views
Kubernetes POD sends RST packet intermittantly
I have a test application which is java Springboot web app. It has a GET API which has latency of 1 second.
I invoke this REST api the rate of 50 calls/minute and it works okay, no errors on ingress ...
1
vote
0
answers
81
views
how can I properly finish a client-initiated TCP 4-way teardown (Close() isn't working)?
I am writing both a client and server in GO, and want to have the option to change between UDP and TCP for the same single piece of data that needs communicating. (Im using TCP for less reliable ...
0
votes
0
answers
92
views
read() appends extra 'FF' at the end
I am trying to build a redis clone. I've set up simple TCP server that listens for client's request, and processes them.
//snippet begin
if (server_fd == -1) {
printf("...
0
votes
1
answer
359
views
TCP packet being sent is exceeding the MSS of a connection -- how is this possible?
I'm very new to networking/network driver design principles and would love some help and direction troubleshooting an odd behavior I'm seeing from a tcpdump captured within a device.
The logs are ...
4
votes
2
answers
205
views
How to send and receive an empty tcp segment?
I try to understand and document how tcp works in some corner-cases.
Here I’m talking about an IP packet, containing a TCP segment that have a zero-length data part.
Zero-length udp datagram seems ...
1
vote
1
answer
133
views
I'm trying to send TCP SYN packet in java using Pcap4j library, but I get a NullPointerException on line "ipv4Builder.build();"
Code and Error should explain my problem (and if not, I can explain more)
Code:
import org.pcap4j.core.*;
import org.pcap4j.packet.*;
import org.pcap4j.packet.namednumber.TcpPort;
import org.pcap4j....
0
votes
1
answer
88
views
Is it possible to lose a message in a WebSocket without losing the connection?
Everywhere I’ve looked for information about reliability and delivery guarantees in WebSockets, it says that it operates over TCP, which means lost packets will be automatically resent.
However, when ...
1
vote
1
answer
35
views
Flutter application closes without any error when connecting to TCP connection in release mode
I've developed a Flutter application that connects to a TCP server and sends data using the basic dart:io package:
_socket = await Socket.connect(MyConst.remoteHost, MyConst.remotePort);
It works ...
2
votes
3
answers
245
views
TCP connections not being cleaned up in Windows (python)
I'm running a Windows server on AWS that is serving some data to IOT devices, but after a while the server stops responding to requests because it hangs on the s.accept() call, I've managed to ...
0
votes
0
answers
84
views
C# TCP Socket for File Transfer - Many Small Packets vs One Big Packet
I'm building a full-stack application where the server is to be capable of maintaining connections with multiple clients at the same time. Communication will be done via TCP-IP. Since most of the data ...
0
votes
1
answer
44
views
Custom newline chracter in python socketserver.StreamRequestHandler
I'm implementing a socket server for python. Ideally I would use a socketserver.TCPServer in combination with thereadline-functionality of socketserver.StreamRequestHandler, see for instance the ...
0
votes
1
answer
90
views
Linux socket data sit in send queue until receive timeout
When sending data as a TCP client under Linux, it occasionally happens that the write operation is successful, but the data seems to remain in the send buffer and is only sent out after a receive ...
1
vote
1
answer
72
views
boost::asio reading all data from an ssl stream (without using EOF and connection: close headers)
i am developing a program that needs to read all the data from a boost::asio::ssl::stream<boost::beast::tcp_stream>, etc a http webpage.
I have tried reading until EOF which works however it ...
0
votes
1
answer
191
views
Problem connecting Delphi client application to service via TCP/IP
I'm trying to connect my client application written in Delphi to a service running on a server using TCP/IP. The service is also written in Delphi and uses TIdTCPServer to listen for connections. When ...
0
votes
0
answers
96
views
Getting "Extra Data" error when trying to json.loads on two separate json strings
I have a program that involves sending python dicts that are converted into json using json.dumps back and forth to a server. I have one json response coming back from the server, which I then use ...
2
votes
1
answer
2k
views
Can't connect to server through pinggy tcp ssh tunnel
I am trying to setup TCP communication between a client and a server in different networks.
Since I do not own a public server and don't want to setup port forwarding, an option was to use TCP ...
1
vote
0
answers
351
views
How to find the place where there are problems with TCP, TCPOFOQueue?
In my project I use NATS JetStream, I use publish to stream rps request, this means that the client will wait for a response from the server, but often there is a timeout error, what the problem is, ...
1
vote
2
answers
263
views
TCP server in C and `while(1)` to keep listening
I would like to create a simple example TCP server in C. It should be able to receive multiple client connections and to send a string to each of them separately, before closing the connection.
Many ...
0
votes
1
answer
105
views
Spring integration: Issue with Listening to TcpConnectionOpenEvent and TcpConnectionCloseEvent along with interceptors
I'm working with Spring Integration and trying to handle TcpConnectionOpenEvent and TcpConnectionCloseEvent to collect metrics on the connections and to write to the log. However, I'm not able to ...
1
vote
2
answers
962
views
Unable to acquire a buffer item, very likely client tried to acquire more than maxImages buffers
I'm using socket for wireless screencast of client screenbuffers on server. I'm using MediaProjection for screencast. Using below code snippet I'm receiving client screen's screenbuffer on server but ...
0
votes
1
answer
343
views
Connect to an external database over HTTP Proxy with .NET Core
My requirement is to connect to an external SQL Server database from my organization network. My .NET Core application is hosted in Openshift Container and it has to go through an internal Bluecoat ...
0
votes
0
answers
199
views
Is it ok to cast a void* pointer, pointing to a buffer, multiple times to pointers of different structs?
I have been trying to implement a TCP/IP stack in C++ for learning.
The issue is when I try to interpret the Ethernet frame and extract information from the header. I use memcpy(),
std::memcpy(&...
0
votes
1
answer
109
views
stack smashing detected on function return
I have function for reading TCP packet of unknown size. The function uses MSG_PEEK to find the required size for the received JSON message (the \"} in the loop condition) and then runs the loop ...
-3
votes
1
answer
92
views
Socket Server Multithreading Java NIO
i need help to create a multithreaded java socket server that can handle and process the request asynchronously.
What i did right now is i created java NIO Socket Server and Client, the client will ...
0
votes
1
answer
154
views
How do I configure the loging in Open Liberty to trace tcp connection details (like keep-alive behavior)?
I want to debug the network layer in Open Libery (OL), with the focus on keep alive behavior. For that, I want to enabled tracing in OL's server.xml. Something like the following:
<logging ...
0
votes
1
answer
51
views
Why is downloading a file from a webserver using HTTP faster than transferring it locally using R(eliable)UDP?
So I downloaded this 1gb file from here and it took about 20-30 seconds (I was using wget not sure if it matters).
Then I tried transferring the file using a Python script that implements Namuyan's ...
0
votes
1
answer
385
views
Tcp server not responding to SYN packets generated from scapy
I have a very simple tcp server socket listening for new connections.
use std::net::TcpListener;
fn main() {
let listener = TcpListener::bind("127.0.0.1:7878").expect("Failed to ...
1
vote
1
answer
111
views
passed a socket to a method which is wrapped with shared ptr but beast tcp stream socket generate error stating that the socket is deleted
void connections::start_acceptor(){
auto socket=std::make_shared<boost::asio::ip::tcp::socket>(ioc);
con_acceptor.async_accept(*socket,[this,socket](const boost::system::error_code ec){...
0
votes
1
answer
131
views
Issue with TCP Packet Data: Received Packet Data Does Not Match Sent Packet
I am working on a network application where I send and receive TCP packets. However, I’m encountering an issue where the data received does not match the data sent. I’m using raw sockets and ...
-1
votes
1
answer
41
views
Can read receipts implemented at the IPv4/TCP Layer detect data harvesting on a server?
I'm working on a project where I'm planning to implement custom read receipts at the IPv4/TCP layer by modifying the BSD networking stack.
My goal is to detect if someone is harvesting data from my ...
1
vote
1
answer
132
views
What to set via setsockopt() to receive jumbo frames?
I have a TCP connection and I would like to improve network throughput by receiving Jumbo frames.
My network allows jumbo frames through hosts/routers etc.
What do I need to set via setsockopt() to ...
2
votes
0
answers
893
views
My mini cube wont register to API server and TCP keeps shutting down I've stopped and started the service 100 times with different combinations of cmd [closed]
PS C:\\Windows\\system32\\submarine\> minikube addons enable yakd
! yakd is a 3rd party addon and is not maintained or verified by minikube maintainers, enable at your own risk.
* yakd is ...
2
votes
0
answers
84
views
setsockopt Timeout Not working Properly In Raspberry Pi
I am working with Raspberry Pi 4 with bookworm 64bit OS for connecting devices with TCP/IP.
I need some delay for socket timeout if no response from my server. The Raspberry Pi acts as a client. I am ...
1
vote
0
answers
29
views
C# Single NetworkStream creates both Reader and Writer, are they independent? [duplicate]
Until now I've had no dealing with NetworkStream and am having to use it for some TCP comms with a tcp enabled device, but I'm seeing some strange behaviour and it's got me asking the question above......
1
vote
1
answer
126
views
MarkLogic- TCP Connection timeout issue during MarkLogic - Roxy deployment
We have recently migrated the cluster from Classic Load Balancer (CLB) to Application Load Balancer (ALB) and tried to deploy the XQuery modules using Roxy along XDBC/XCC with an SSL enabled port. We ...
0
votes
0
answers
65
views
Add script to IP port on Microsoft Server 2019 as Print Server
Im currently trying to setup fake printer on server to obtain files and store them on disc to use them in another app. I need to intercept print request from other computer when it choose this fake ...
0
votes
1
answer
112
views
declared implicitly some func STM32 LWIP
I have the following problem: there is a version of LWIP v.1.11.2 that is suitable for my project, after I installed it from github and selected the desired version in CubeMX and generated the code, I ...
-1
votes
2
answers
133
views
C socket program stuck at listen()
I am trying to learn socket programming in C and i was trying to setup a basic TCP connection between client and server however in my server.c my code is seemingly just stuck at listen(). It does not ...
1
vote
0
answers
35
views
Remote tcp connexion to postgresql not responding
I can't connect to my remote postgresql server.
I'm on a local network containing my server (192.168.1.2) and my development workstation (192.168.1.3). I can't connect to my database on port 5432. My ...
2
votes
1
answer
75
views
Do I have to synchronize TcpStream::write_all calls to avoid interleaving?
I have a TcpStream (from the standard library) and would like to write to it from multiple threads. TcpStream allows this without additional synchronization due to impl Write for &TcpStream. The ...
1
vote
1
answer
795
views
tcpdump does not capture all packets at high packet frequency
Let’s say, there is some TCP (unencrypted) traffic you would like to eavesdrop packets and send them somewhere else. You don’t want to interrupt the traffic or interfere to its parts, just eavesdrop ...
1
vote
0
answers
34
views
The message that the server sends to a client through TCP in Java gets changed when the client receives it
I'm working on an online game. For communication between clients and the server, I'm using TCP. Now, when clients send their usernames to the server, the server should message them back '1', but the ...
0
votes
1
answer
222
views
Why can I successfully connect to a netcat server from the adb shell and not from the Android app?
I'm trying to send a TCP message to a netcat server running on the machine where an Android device is connected.
In order to do so, I'm executing the following steps on the host:
adb reverse tcp:3000 ...
-1
votes
1
answer
182
views
Netty TCP Server keep connection open on custom exceptions
I wrote a TCP Server using project reactor netty that receives a byte array request message from a client, processes it, then returns a byte array response message to the client. The connections ...
1
vote
1
answer
814
views
Aeron vs ZeroMQ: What is the distinction between transport and messaging?
This question is motivated by the discussion in this GitHub issue.
I asked Edge Copilot the same but I don't fully trust LLMs. Here is an excerpt from that chat
Aeron: Provides a high-performance, ...
0
votes
1
answer
281
views
How can I receive TCP messages using Azure Functions or Logic Apps?
I'm looking to receive TCP messages using Azure Functions or Logic Apps. I understand that both services are typically triggered by HTTP requests, but I'm wondering if there's a way to run a TCP ...
2
votes
1
answer
203
views
How to message using zmq with remote machines
I was planning to use zmq to communicate between a personal laptop and a remote machine. I plan to use the laptop as the server and the remote machine as a client. Currently, I use a vpn to get into ...