Gitea has insecure default SSH settings
The built-in SSH server currently advertises a number of key exchange, MAC, and host key algorithms that are considered weak or broken. The defaults should be tightened so a fresh installation passes a baseline SSH security audit out of the box.
Running ssh-audit against a default deployment flags the following as fail:
ecdh-sha2-nistp256ecdh-sha2-nistp384ecdh-sha2-nistp521hmac-sha1ssh-rsa```sh
docker run -it --rm positronsecurity/ssh-audit -p 2222 gitea.local
```
Default deployments expose algorithms that are known-weak or deprecated upstream. The current workaround requires manually setting several GITEA__server__SSH_SERVER_* variables, which most users will never do.
```ini
[server]
SSH_SERVER_KEY_EXCHANGES = curve25519-sha256, diffie-hellman-group14-sha256
SSH_SERVER_CIPHERS = chacha20-poly1305@openssh.com, aes128-ctr, aes192-ctr, aes256-ctr, aes128-gcm@openssh.com, aes256-gcm@openssh.com
SSH_SERVER_MACS = hmac-sha2-256-etm@openssh.com, hmac-sha2-256
```
There is no exposed option to restrict host key algorithms, so ssh-rsa remains advertised.
SSH_SERVER_KEY_EXCHANGES, SSH_SERVER_CIPHERS, and SSH_SERVER_MACS updated to the secure list above.SSH_SERVER_HOST_KEY_ALGORITHMS option added, with a default that excludes ssh-rsa.ssh-audit against a fresh install reports no [fail] entries.This issue can be reached over the network, attack complexity is high, an attacker needs no privileges on the target. No user interaction is required. Rated impact: confidentiality low, integrity low, availability none.
GHSA-3m6q-h5gj-7mrw is classified as CWE-1188: Insecure Default Initialization of Resource. Default settings are insecure, so an installation is exposed until someone changes them.
GHSA-3m6q-h5gj-7mrw is recorded against 1 package.
Published on 22 April 2026 and last revised on 25 June 2026. No public exploit is currently recorded for this entry. Record sourced from OSV.
Details
CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
Affected Packages
| Software | From version | Fixed in |
|---|---|---|
| code.gitea.io/gitea | — | — |
References
Similar Threats
Free Vulnerability Check
BotEraser helps you identify potentially vulnerable plugins and themes by checking your installation against GHSA-3m6q-h5gj-7mrw and other known CVE records.
Scan My Site Free →No credit card required · Results in minutes
ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.
Stay up to date with the latest from Boteraser.
We use cookies to improve your experience on our site. By using our site, you consent to cookies.
Manage your cookie preferences below:
Essential cookies enable basic functions and are necessary for the proper function of the website.
CloudFlare provides web performance and security solutions, enhancing site speed and protecting against threats.
Service URL: developers.cloudflare.com (opens in a new window)
These cookies are needed for adding comments on this website.
These cookies are used for managing login functionality on this website.
Statistics cookies collect information anonymously. This information helps us understand how visitors use our website.
Google Analytics is a powerful tool that tracks and analyzes website traffic for informed marketing decisions.
Service URL: policies.google.com (opens in a new window)
You can find more information in our Cookie Policy and Privacy Policy.