aboutsummaryrefslogtreecommitdiffstats
path: root/common/iobuf.h
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2014-06-25 18:25:28 +0000
committerWerner Koch <[email protected]>2014-06-30 07:12:48 +0000
commitc434de4d83ccfaca8bde51de5c2ac8d9656e4e18 (patch)
tree07987f47300ad446063273961acf0437af24a2d2 /common/iobuf.h
parentcommon: Minor code cleanup for a legacy OS. (diff)
downloadgnupg-c434de4d83ccfaca8bde51de5c2ac8d9656e4e18.tar.gz
gnupg-c434de4d83ccfaca8bde51de5c2ac8d9656e4e18.zip
gpg: Create exported secret files and revocs with mode 700.
* common/iobuf.c (direct_open): Add arg MODE700. (iobuf_create): Ditto. * g10/openfile.c (open_outfile): Add arg RESTRICTEDPERM. Change call callers to pass 0 for it. * g10/revoke.c (gen_desig_revoke, gen_revoke): Here pass true for new arg. * g10/export.c (do_export): Pass true for new arg if SECRET is true. -- GnuPG-bug-id: 1653. Note that this works only if --output has been used.
Diffstat (limited to 'common/iobuf.h')
-rw-r--r--common/iobuf.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/iobuf.h b/common/iobuf.h
index d3f55206e..ef055477e 100644
--- a/common/iobuf.h
+++ b/common/iobuf.h
@@ -115,7 +115,7 @@ iobuf_t iobuf_fdopen (int fd, const char *mode);
iobuf_t iobuf_fdopen_nc (int fd, const char *mode);
iobuf_t iobuf_esopen (estream_t estream, const char *mode, int keep_open);
iobuf_t iobuf_sockopen (int fd, const char *mode);
-iobuf_t iobuf_create (const char *fname);
+iobuf_t iobuf_create (const char *fname, int mode700);
iobuf_t iobuf_append (const char *fname);
iobuf_t iobuf_openrw (const char *fname);
int iobuf_ioctl (iobuf_t a, iobuf_ioctl_t cmd, int intval, void *ptrval);