aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/security.h
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2002-05-13 12:10:49 +0000
committerCorinna Vinschen <corinna@vinschen.de>2002-05-13 12:10:49 +0000
commit043bc3e1eea5042ef269f4f2b6aa6cb760b23fcd (patch)
tree997ee8941dbdca2d08d87c4d14fd98737c658ee3 /winsup/cygwin/security.h
parent6eabab557a557abd532eb8f1b089c7814950b37f (diff)
downloadnewlib-043bc3e1eea5042ef269f4f2b6aa6cb760b23fcd.zip
newlib-043bc3e1eea5042ef269f4f2b6aa6cb760b23fcd.tar.gz
newlib-043bc3e1eea5042ef269f4f2b6aa6cb760b23fcd.tar.bz2
* shared.cc (__sec_user): Split into sec_acl() and call orig_sid().
(sec_acl): Create from part of __sec_user(), except creator/owner. * security.h: Define sec_acl() and MAX_DACL_LEN.
Diffstat (limited to 'winsup/cygwin/security.h')
-rw-r--r--winsup/cygwin/security.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/winsup/cygwin/security.h b/winsup/cygwin/security.h
index 220f571..8b95ad0 100644
--- a/winsup/cygwin/security.h
+++ b/winsup/cygwin/security.h
@@ -16,6 +16,8 @@ details. */
#define DEFAULT_GID DOMAIN_ALIAS_RID_ADMINS
#define MAX_SID_LEN 40
+#define MAX_DACL_LEN(n) (sizeof (ACL) \
+ + (n) * (sizeof (ACCESS_ALLOWED_ACE) - sizeof (DWORD) + MAX_SID_LEN))
#define NO_SID ((PSID)NULL)
@@ -201,6 +203,7 @@ SECURITY_DESCRIPTOR *__stdcall get_null_sd (void);
extern SECURITY_ATTRIBUTES sec_none, sec_none_nih, sec_all, sec_all_nih;
extern SECURITY_ATTRIBUTES *__stdcall __sec_user (PVOID sa_buf, PSID sid2, BOOL inherit)
__attribute__ ((regparm (3)));
+extern BOOL sec_acl (PACL acl, BOOL admins, PSID sid1 = NO_SID, PSID sid2 = NO_SID);
int __stdcall NTReadEA (const char *file, const char *attrname, char *buf, int len);
BOOL __stdcall NTWriteEA (const char *file, const char *attrname, const char *buf, int len);