diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2003-11-04 18:48:19 +0300 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2003-11-04 18:48:19 +0300 |
commit | bcd06214e106481e7a5e86560365cca8a3549752 (patch) | |
tree | 7c07b247d7e300e585d3f77853fdc938bfbde9e1 /winsup/cygwin/sec_helper.cc | |
parent | c35391d0d2b0c5fd057aa1ccd4c215a0082919d5 (diff) |
* external.cc (cygwin_internal): Add CW_GET_POSIX_SECURITY_ATTRIBUTE
handling.
* include/cygwin/version.h: Bump API minor number.
* include/sys/cygwin.h (cygwin_getinfo_types): Add
CW_GET_POSIX_SECURITY_ATTRIBUTE.
* exceptions.cc (init_global_security): Move from here...
* sec_helper.cc (init_global_security): ...to here.
Diffstat (limited to 'winsup/cygwin/sec_helper.cc')
-rw-r--r-- | winsup/cygwin/sec_helper.cc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/winsup/cygwin/sec_helper.cc b/winsup/cygwin/sec_helper.cc index dda352543..ccd8d4487 100644 --- a/winsup/cygwin/sec_helper.cc +++ b/winsup/cygwin/sec_helper.cc @@ -371,6 +371,24 @@ get_null_sd () return null_sdp; } +/* + * Initialize global security attributes. + * + * Called from dcrt0.cc (_dll_crt0). + */ + +void +init_global_security () +{ + sec_none.nLength = sec_none_nih.nLength = + sec_all.nLength = sec_all_nih.nLength = sizeof (SECURITY_ATTRIBUTES); + sec_none.bInheritHandle = sec_all.bInheritHandle = TRUE; + sec_none_nih.bInheritHandle = sec_all_nih.bInheritHandle = FALSE; + sec_none.lpSecurityDescriptor = sec_none_nih.lpSecurityDescriptor = NULL; + sec_all.lpSecurityDescriptor = sec_all_nih.lpSecurityDescriptor = + get_null_sd (); +} + BOOL sec_acl (PACL acl, bool original, bool admins, PSID sid1, PSID sid2, DWORD access2) { |