<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>networking on Ikoma's Blog</title><link>https://blog.yusukeikoma.com/tags/networking/</link><description>Recent content in networking on Ikoma's Blog</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Mon, 05 Oct 2026 13:20:23 +0900</lastBuildDate><atom:link href="https://blog.yusukeikoma.com/tags/networking/index.xml" rel="self" type="application/rss+xml"/><item><title>UDP connect() Sends Nothing, and getsockname() Gives You Your Local IP</title><link>https://blog.yusukeikoma.com/posts/udp-connect-local-ip/</link><pubDate>Mon, 05 Oct 2026 13:20:23 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/udp-connect-local-ip/</guid><description>A machine with Wi-Fi, a VPN and a container bridge has several addresses, and a hostname lookup can return the wrong one. Connecting a UDP socket to a destination makes the kernel pick the source address it would use, and getsockname() reads it back without a single packet being sent. Checked on Linux with three interfaces: five destinations, five answers, no IPv4 or ARP frames on the wire.</description></item><item><title>Cancel the Stream, Not the Connection, When One HTTP/2 Request Times Out</title><link>https://blog.yusukeikoma.com/posts/http2-timeout-stream-vs-connection/</link><pubDate>Tue, 08 Sep 2026 12:56:00 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/http2-timeout-stream-vs-connection/</guid><description>A request deadline fired on a connection that carries many requests at once. Do you close the connection, or only the request? In a small Node lab, closing the HTTP/2 session failed two innocent requests, while cancelling only the stream let them finish on the same TCP connection. The same lab shows the one case where cancelling is not enough: a lost packet stalls every stream on a TCP connection, and a connection-level PING is the right way to tell.</description></item><item><title>Waiting for bufferedAmount Protects the Sender, Not a Slow Consumer</title><link>https://blog.yusukeikoma.com/posts/websocket-bufferedamount-backpressure/</link><pubDate>Sun, 06 Sep 2026 20:54:24 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/websocket-bufferedamount-backpressure/</guid><description>WebSocket send() never waits, and bufferedAmount only sees the part of the path that is in your own process. In a small lab, a sender that politely waited for bufferedAmount to drain still let a slow consumer queue nearly all 400 messages in its own memory, while a credit window of 8 kept the backlog at 8. This post goes through four common beliefs about send(), bufferedAmount, message size and backpressure, tests each one, and ends with a table for choosing between them.</description></item><item><title>Two write() Calls Can Stall a TCP Connection for 40 ms</title><link>https://blog.yusukeikoma.com/posts/two-small-writes-nagle-delayed-ack/</link><pubDate>Tue, 01 Sep 2026 20:56:28 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/two-small-writes-nagle-delayed-ack/</guid><description>Send a header and a body as two small write() calls, then wait for a reply, and every round trip can stall for about 40 ms on an idle machine with an idle network. Neither Nagle&amp;rsquo;s algorithm nor delayed ACK is a bug; together they deadlock until a timer fires. This post predicts the stall, reproduces it with a 50-line script, reads it off a packet trace, and compares the four ways out.</description></item><item><title>A Dead TCP Peer Goes Unnoticed for 15 Minutes on Writes, Forever on Reads</title><link>https://blog.yusukeikoma.com/posts/tcp-half-open-connection-detection/</link><pubDate>Sun, 23 Aug 2026 15:09:06 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/tcp-half-open-connection-detection/</guid><description>TCP never tells you that the peer is gone. A reader blocks forever, a writer keeps retransmitting for a quarter of an hour, and SO_KEEPALIVE does nothing while data is unacknowledged. This post builds a one-file Linux lab with no root, climbs a ladder of mechanisms (nothing, keepalive, TCP_USER_TIMEOUT, an application heartbeat), measures how long each takes to notice, and shows where NAT and the RFCs fit in.</description></item><item><title>When a WebSocket Outlives Its Token</title><link>https://blog.yusukeikoma.com/posts/websocket-reauthentication-on-long-lived-connections/</link><pubDate>Fri, 21 Aug 2026 13:34:18 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/websocket-reauthentication-on-long-lived-connections/</guid><description>After the 101 response, no request carries credentials: the server remembers a verdict, not the evidence. This article follows one token through a browser handshake, shows what a page can and cannot see, and compares three ways to renew it (reconnect, in-band, out-of-band) with a runnable server, tests, and a headless-Chrome check.</description></item><item><title>Keeping an Agent Resident Behind NAT</title><link>https://blog.yusukeikoma.com/posts/resident-agent-behind-nat/</link><pubDate>Mon, 03 Aug 2026 19:03:09 +0900</pubDate><guid>https://blog.yusukeikoma.com/posts/resident-agent-behind-nat/</guid><description>Designing a resident agent behind NAT with outbound connections, separate liveness checks, and on-demand SSH sessions for interactive access.</description></item></channel></rss>