Change internal gid datatype from __gid16_t to __gid32_t
throughout. * cygwin.din: Export new symbols chown32, fchown32, getegid32, getgid32, getgrgid32, getgrnam32, getgroups32, initgroups32, lchown32, setgid32, setegid32, getgrent32. * grp.cc (grp32togrp16): New static function. (getgrgid32): New function. (getgrnam32): Ditto. (getgrent32): Ditto. (getgroups32): Change name of internal function from getgroups. (getgroups32): New function. (initgroups32): Ditto. * syscalls.cc (chown32): Ditto. (lchown32): Ditto. (fchown32): Ditto. (setegid32): Ditto. (setgid32): Ditto. * uinfo.cc (getgid32): Ditto. (getegid32): Ditto. * include/cygwin/grp.h: Remove declaration of getgrgid() and getgrnam(). Declare getgrgid32() and getgrnam32() instead. Declare getgid32().
This commit is contained in:
@@ -57,7 +57,7 @@ public:
|
||||
inline PSID set () { return psid = (PSID) sbuf; }
|
||||
|
||||
BOOL getfrompw (const struct passwd *pw);
|
||||
BOOL getfromgr (const struct __group16 *gr);
|
||||
BOOL getfromgr (const struct __group32 *gr);
|
||||
|
||||
int get_id (BOOL search_grp, int *type = NULL);
|
||||
inline int get_uid () { return get_id (FALSE); }
|
||||
@@ -161,14 +161,14 @@ extern BOOL allow_smbntsec;
|
||||
and group lists so they are somehow security related. Besides that
|
||||
I didn't find a better place to declare them. */
|
||||
extern struct passwd *internal_getpwent (int);
|
||||
extern struct __group16 *internal_getgrent (int);
|
||||
extern struct __group32 *internal_getgrent (int);
|
||||
|
||||
/* File manipulation */
|
||||
int __stdcall set_process_privileges ();
|
||||
int __stdcall get_file_attribute (int, const char *, int *,
|
||||
__uid16_t * = NULL, __gid16_t * = NULL);
|
||||
__uid16_t * = NULL, __gid32_t * = NULL);
|
||||
int __stdcall set_file_attribute (int, const char *, int);
|
||||
int __stdcall set_file_attribute (int, const char *, __uid16_t, __gid16_t, int, const char *);
|
||||
int __stdcall set_file_attribute (int, const char *, __uid16_t, __gid32_t, int, const char *);
|
||||
LONG __stdcall read_sd(const char *file, PSECURITY_DESCRIPTOR sd_buf, LPDWORD sd_size);
|
||||
LONG __stdcall write_sd(const char *file, PSECURITY_DESCRIPTOR sd_buf, DWORD sd_size);
|
||||
BOOL __stdcall add_access_allowed_ace (PACL acl, int offset, DWORD attributes, PSID sid, size_t &len_add, DWORD inherit);
|
||||
@@ -190,7 +190,7 @@ void extract_nt_dom_user (const struct passwd *pw, char *domain, char *user);
|
||||
BOOL get_logon_server_and_user_domain (char *logonserver, char *domain);
|
||||
|
||||
/* sec_helper.cc: Security helper functions. */
|
||||
BOOL __stdcall is_grp_member (__uid16_t uid, __gid16_t gid);
|
||||
BOOL __stdcall is_grp_member (__uid32_t uid, __gid32_t gid);
|
||||
/* `lookup_name' should be called instead of LookupAccountName.
|
||||
* logsrv may be NULL, in this case only the local system is used for lookup.
|
||||
* The buffer for ret_sid (40 Bytes) has to be allocated by the caller! */
|
||||
@@ -209,7 +209,7 @@ extern BOOL sec_acl (PACL acl, BOOL admins, PSID sid1 = NO_SID, PSID sid2 = NO_S
|
||||
|
||||
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);
|
||||
PSECURITY_DESCRIPTOR alloc_sd (uid_t uid, gid_t gid, const char *logsrv, int attribute,
|
||||
PSECURITY_DESCRIPTOR alloc_sd (__uid16_t uid, __gid32_t gid, const char *logsrv, int attribute,
|
||||
PSECURITY_DESCRIPTOR sd_ret, DWORD *sd_size_ret);
|
||||
|
||||
extern inline SECURITY_ATTRIBUTES *
|
||||
|
Reference in New Issue
Block a user