0c000af72162a5bd5147e8eedd25e810619f6c6f
- Author
- Marc Cornellà <marc.cornella@live.com>
- Committer
- GitHub <noreply@github.com>
- Date
Message
cloudapp: fix permissions of credentials file
Fixes #4151
Diff
1diff --git a/plugins/cloudapp/cloudapp.plugin.zsh b/plugins/cloudapp/cloudapp.plugin.zsh
2index 99252f690b13c0d247024187858c759898d9474f..3b363c81b3d4426d6ae79e655a05e8a904a7c44f 100644
3--- a/plugins/cloudapp/cloudapp.plugin.zsh
4+++ b/plugins/cloudapp/cloudapp.plugin.zsh
5@@ -1,2 +1,6 @@
6-#!/bin/zsh
7-alias cloudapp=$ZSH/plugins/cloudapp/cloudapp.rb
8+alias cloudapp="${0:a:h}/cloudapp.rb"
9+
10+# Ensure only the owner can access the credentials file
11+if [[ -f ~/.cloudapp ]]; then
12+ chmod 600 ~/.cloudapp
13+fi