Port 9418 is the Git native protocol (git://) port for read-only anonymous repository access. The git:// protocol has no encryption and no authentication – it is faster than HTTPS for public repository cloning but provides no security. Use HTTPS or SSH for any repository requiring access control or privacy.
Port Number
9418
Protocol
TCP
Service
Git Native Protocol (git://)
Range
IANA Registered (1024–49151)
Test if git:// protocol is responding and list remote refs
git ls-remote git://host/repo.gitDetect git-daemon remotely (should be closed on non-mirror servers)
nmap -sV -p 9418 targetCheck if git-daemon is running locally
ss -tnlp sport = :9418Verify git-daemon flags (check for --export-all or --enable=receive-pack)
ps aux | grep git-daemon | grep -v grepgit clone git://github.com/torvalds/linux.git (deprecated on GitHub)
git daemon --reuseaddr --base-path=/srv/git /srv/git
git daemon --export-all --enable=receive-pack (DANGEROUS – enables anonymous push)The git:// protocol was created alongside Git itself by Linus Torvalds in 2005 for fast Linux kernel distribution. Port 9418 was registered with IANA for the Git protocol. In Git's early years, git:// was the fastest way to clone large repositories (no TLS handshake, no HTTP overhead). GitHub supported git:// until 2022, when it was removed due to security concerns. Modern Git Smart HTTP protocol (2010) with TLS 1.3 performs comparably to git:// while providing authentication and encryption.
Is there any reason to still use git:// in 2024+?
Almost never. The performance advantage over HTTPS is negligible with modern TLS (1.3) and HTTP/2 multiplexing. The only remaining use case is high-volume public mirror servers (kernel.org) where authentication overhead matters at scale and the content is intentionally public. For anything else: SSH for developers, HTTPS for CI/CD and anonymous read access.
How do I disable git:// on my server?
Stop git-daemon: systemctl disable --now git-daemon. Remove inetd/xinetd entries for port 9418. Firewall: iptables -A INPUT -p tcp --dport 9418 -j DROP. Verify: nmap -p 9418 localhost shows closed. Migrate clients to HTTPS (git remote set-url origin https://...) or SSH (git remote set-url origin git@host:repo.git).