diff options
author | Sam Hartman <hartmans@mit.edu> | 2002-03-03 01:10:01 +0000 |
---|---|---|
committer | Sam Hartman <hartmans@mit.edu> | 2002-03-03 01:10:01 +0000 |
commit | 781a967c2f1a2fc2c65f4ea96cfdf549dfc971f4 (patch) | |
tree | 2a2c91ff6389e793f8e29bd5be8931d07ca1e5c8 /src/kadmin/ktutil | |
parent | 5973ec84c354171322d5ad56a6529d89d8e9c100 (diff) | |
download | krb5-781a967c2f1a2fc2c65f4ea96cfdf549dfc971f4.zip krb5-781a967c2f1a2fc2c65f4ea96cfdf549dfc971f4.tar.gz krb5-781a967c2f1a2fc2c65f4ea96cfdf549dfc971f4.tar.bz2 |
Set umask to 077 to avoid public srvtabs
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14213 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/kadmin/ktutil')
-rw-r--r-- | src/kadmin/ktutil/ChangeLog | 6 | ||||
-rw-r--r-- | src/kadmin/ktutil/ktutil_funcs.c | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/kadmin/ktutil/ChangeLog b/src/kadmin/ktutil/ChangeLog index e7bc046..e3b63c3 100644 --- a/src/kadmin/ktutil/ChangeLog +++ b/src/kadmin/ktutil/ChangeLog @@ -1,3 +1,9 @@ +2002-03-02 Sam Hartman <hartmans@mit.edu> + + * ktutil_funcs.c (ktutil_write_srvtab): Set umask to 077 to avoid + public srvtabs. + + 2001-10-09 Ken Raeburn <raeburn@mit.edu> * ktutil.h: Make prototypes unconditional. diff --git a/src/kadmin/ktutil/ktutil_funcs.c b/src/kadmin/ktutil/ktutil_funcs.c index 94d5b5e..3d8f0d6 100644 --- a/src/kadmin/ktutil/ktutil_funcs.c +++ b/src/kadmin/ktutil/ktutil_funcs.c @@ -508,6 +508,9 @@ krb5_error_code ktutil_write_srvtab(context, list, name) /* Check if lp->entry is newer kvno; if so, update */ lp1->entry = lp->entry; } + umask(0077); /*Changing umask for all of ktutil is OK + * We don't ever write out anything that should use + * default umask.*/ fp = fopen(name, "w"); if (!fp) { retval = EIO; |