Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

README update: Use umask when creating token file #303

Merged
merged 1 commit into from
Sep 2, 2019

Conversation

Umofomia
Copy link
Contributor

@Umofomia Umofomia commented Aug 29, 2019

The originally suggested command in the README for manually setting up the ~/.gist token file does not ensure that the correct file permissions are set on the file, which may expose the token to other user accounts on the system.

I'm changing the documentation to instead suggest running umask 0077 before creating the file to ensure that no other user accounts on the system will have access to it. In addition, by putting the entire command in parentheses, the command is executed within a subshell so that the umask is only set temporarily for the purposes of creating the file:

(umask 0077 && echo MY_SECRET_TOKEN > ~/.gist)

The originally suggested command in the README for manually setting up the `~/.gist` token file does not ensure that the correct file permissions are set on the file, which may expose the token to other user accounts on the system.

I'm changing to the documentation to instead suggest running `umask 0077` before creating the file to ensure that no other user accounts on the system will have access to it. In addition, by putting the entire command in parentheses, the command is executed within a subshell so that the umask is only set temporarily for the purposes of creating the file:

```sh
(umask 0077 && echo MY_SECRET_TOKEN > ~/.gist)
```
@ConradIrwin ConradIrwin merged commit 02ab846 into defunkt:master Sep 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants