Skip to content
Snippets Groups Projects
Unverified Commit 0fc5a8e8 authored by Joona Hoikkala's avatar Joona Hoikkala Committed by GitHub
Browse files

Use umask 0077 across the process in order to have the created files readable...

Use umask 0077 across the process in order to have the created files readable only by the acme-dns user (#102)
parent ec013c0f
Branches
Tags
No related merge requests found
......@@ -7,6 +7,7 @@ import (
stdlog "log"
"net/http"
"os"
"syscall"
"github.com/julienschmidt/httprouter"
"github.com/rs/cors"
......@@ -15,6 +16,8 @@ import (
)
func main() {
// Created files are not world writable
syscall.Umask(0077)
// Read global config
var err error
if fileIsAccessible("/etc/acme-dns/config.cfg") {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment