permissions on data/ssh on fresh install = drwxr-xr-x (world readable) #14113

Open
opened 2025-11-02 11:03:17 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @twoodcock on GitHub (Feb 8, 2025).

Description

This is a minor issue, not a critical issue. The ssh key proper is only readable by the gitea user.

I just created my first gitea installation and I've noted that the ssh directory containing the ssh key is world readable.

If I recall correctly all versions of ssh I have used previously refuse access if the .ssh directory is group or world readable.

I have not attempted to reproduce on the demo site because I would not be able to see the result.
Similarly, I don't think logs are pertinent.
I see this:
Feb 06 17:36:40 pygmyt gitea[34023]: 2025/02/06 17:36:40 modules/ssh/ssh.go:385:Listen() [I] Adding SSH host key: /srv/gitea/data/ssh/gitea.rsa

Gitea Version

Gitea version 1.23.2 built with GNU Make 4.3, go1.23.5 : bindata, sqlite, sqlite_unlock_notify

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

git version 2.43.0

Operating System

Ubuntu 24.04.1 LTS; Linux 6.8.0-51-generic

How are you running Gitea?

Gitea downloaded as per instructions, modified to fetch the .2 version.
wget -O gitea https://dl.gitea.com/gitea/1.23.2/gitea-1.23.2-linux-amd64

running from /usr/local/bin/gitea, symlinked to /usr/local/gitea.d/gitea-1.23.2-linux-amd64.

The working directory is /srv/gitea

Database

MySQL/MariaDB

Originally created by @twoodcock on GitHub (Feb 8, 2025). ### Description This is a minor issue, not a critical issue. The ssh key proper is only readable by the gitea user. I just created my first gitea installation and I've noted that the ssh directory containing the ssh key is world readable. If I recall correctly all versions of ssh I have used previously refuse access if the .ssh directory is group or world readable. I have not attempted to reproduce on the demo site because I would not be able to see the result. Similarly, I don't think logs are pertinent. I see this: Feb 06 17:36:40 pygmyt gitea[34023]: 2025/02/06 17:36:40 modules/ssh/ssh.go:385:Listen() [I] Adding SSH host key: /srv/gitea/data/ssh/gitea.rsa ### Gitea Version Gitea version 1.23.2 built with GNU Make 4.3, go1.23.5 : bindata, sqlite, sqlite_unlock_notify ### Can you reproduce the bug on the Gitea demo site? No ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version git version 2.43.0 ### Operating System Ubuntu 24.04.1 LTS; Linux 6.8.0-51-generic ### How are you running Gitea? Gitea downloaded as per instructions, modified to fetch the .2 version. ```wget -O gitea https://dl.gitea.com/gitea/1.23.2/gitea-1.23.2-linux-amd64``` running from /usr/local/bin/gitea, symlinked to /usr/local/gitea.d/gitea-1.23.2-linux-amd64. The working directory is /srv/gitea ### Database MySQL/MariaDB
GiteaMirror added the type/bug label 2025-11-02 11:03:17 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#14113