[Pkg-mono-svn-commits] [SCM] mono branch, master-experimental, updated. debian/2.10.1-4-37-g03befb1
Mirco Bauer
meebey at meebey.net
Sun Aug 7 16:04:50 UTC 2011
The following commit has been merged in the master-experimental branch:
commit 9f1d890db70fbf605e5358233ad3b24e431c8bd7
Merge: 5ba9f94cb130f8dc3b8470ab6dcdfdb221a2f3df f165789868007ccb2d56b70e6e3cac72f3b6cf22
Author: Mirco Bauer <meebey at meebey.net>
Date: Sun Aug 7 17:46:06 2011 +0200
Merge commit 'upstream/2.10.3' into master-experimental-patches/fix_implicit_pointer_conversion
diff --combined mono/metadata/security.c
index 6e9ee69,c61eab9..ad636f2
--- a/mono/metadata/security.c
+++ b/mono/metadata/security.c
@@@ -13,7 -13,6 +13,7 @@@
#include <mono/metadata/assembly.h>
#include <mono/metadata/appdomain.h>
+#include <mono/metadata/assembly.h>
#include <mono/metadata/image.h>
#include <mono/metadata/exception.h>
#include <mono/metadata/object-internals.h>
@@@ -22,7 -21,7 +22,7 @@@
#include <mono/io-layer/io-layer.h>
#include <mono/utils/strenc.h>
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
#include <aclapi.h>
#include <accctrl.h>
@@@ -60,12 -59,12 +60,12 @@@
#endif /* defined(__GNUC__) */
- #endif /* not PLATFORM_WIN32 */
+ #endif /* not HOST_WIN32 */
/* internal functions - reuse driven */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
/* ask a server to translate a SID into a textual representation */
static gunichar2*
@@@ -114,7 -113,7 +114,7 @@@ GetSidName (gunichar2 *server, PSID sid
}
- #else /* not PLATFORM_WIN32 */
+ #else /* not HOST_WIN32 */
#define MONO_SYSCONF_DEFAULT_SIZE ((size_t) 1024)
@@@ -268,7 -267,7 +268,7 @@@ ves_icall_System_Security_Principal_Win
MONO_ARCH_SAVE_REGS;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
/* Note: This isn't a copy of the Token - we must not close it!!!
* http://www.develop.com/kbrown/book/html/whatis_windowsprincipal.html
*/
@@@ -292,7 -291,7 +292,7 @@@ ves_icall_System_Security_Principal_Win
gunichar2 *uniname = NULL;
gint32 size = 0;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
MONO_ARCH_SAVE_REGS;
GetTokenInformation (token, TokenUser, NULL, size, (PDWORD)&size);
@@@ -313,7 -312,7 +313,7 @@@
uniname = g_utf8_to_utf16 (uname, size, NULL, NULL, NULL);
g_free (uname);
}
- #endif /* PLATFORM_WIN32 */
+ #endif /* HOST_WIN32 */
if (size > 0) {
result = mono_string_new_utf16 (mono_domain_get (), uniname, size);
@@@ -331,7 -330,7 +331,7 @@@
gpointer
ves_icall_System_Security_Principal_WindowsIdentity_GetUserToken (MonoString *username)
{
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
gpointer token = NULL;
MONO_ARCH_SAVE_REGS;
@@@ -342,7 -341,7 +342,7 @@@
*/
g_warning ("Unsupported on Win32 (anyway requires W2K3 minimum)");
- #else /* PLATFORM_WIN32*/
+ #else /* HOST_WIN32*/
#ifdef HAVE_GETPWNAM_R
struct passwd pwd;
@@@ -396,7 -395,7 +396,7 @@@ ves_icall_System_Security_Principal_Win
{
MonoArray *array = NULL;
MonoDomain *domain = mono_domain_get ();
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
gint32 size = 0;
MONO_ARCH_SAVE_REGS;
@@@ -445,7 -444,7 +445,7 @@@ ves_icall_System_Security_Principal_Win
MONO_ARCH_SAVE_REGS;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
result = (CloseHandle (token) != 0);
#endif
return result;
@@@ -459,7 -458,7 +459,7 @@@ ves_icall_System_Security_Principal_Win
MONO_ARCH_SAVE_REGS;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
if (DuplicateToken (token, SecurityImpersonation, &dupe) == 0) {
dupe = NULL;
}
@@@ -497,13 -496,13 +497,13 @@@ ves_icall_System_Security_Principal_Win
{
gboolean result = FALSE;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
MONO_ARCH_SAVE_REGS;
/* The convertion from an ID to a string is done in managed code for Windows */
g_warning ("IsMemberOfGroupId should never be called on Win32");
- #else /* PLATFORM_WIN32 */
+ #else /* HOST_WIN32 */
#ifdef HAVE_GETGRGID_R
struct group grp;
@@@ -538,7 -537,7 +538,7 @@@
g_free (fbuf);
#endif
- #endif /* PLATFORM_WIN32 */
+ #endif /* HOST_WIN32 */
return result;
}
@@@ -549,14 -548,14 +549,14 @@@ ves_icall_System_Security_Principal_Win
{
gboolean result = FALSE;
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
MONO_ARCH_SAVE_REGS;
/* Windows version use a cache built using WindowsIdentity._GetRoles */
g_warning ("IsMemberOfGroupName should never be called on Win32");
- #else /* PLATFORM_WIN32 */
+ #else /* HOST_WIN32 */
gchar *utf8_groupname;
MONO_ARCH_SAVE_REGS;
@@@ -591,7 -590,7 +591,7 @@@
#endif
g_free (utf8_groupname);
}
- #endif /* PLATFORM_WIN32 */
+ #endif /* HOST_WIN32 */
return result;
}
@@@ -599,7 -598,7 +599,7 @@@
/* Mono.Security.Cryptography IO related internal calls */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
static PSID
GetAdministratorsSid (void)
@@@ -848,13 -847,13 +848,13 @@@ Protect (MonoString *path, gint32 file_
return result;
}
- #endif /* not PLATFORM_WIN32 */
+ #endif /* not HOST_WIN32 */
MonoBoolean
ves_icall_Mono_Security_Cryptography_KeyPairPersistence_CanSecure (MonoString *root)
{
- #if PLATFORM_WIN32
+ #if HOST_WIN32
gint32 flags;
MONO_ARCH_SAVE_REGS;
@@@ -879,7 -878,7 +879,7 @@@ ves_icall_Mono_Security_Cryptography_Ke
MONO_ARCH_SAVE_REGS;
/* no one, but the owner, should have write access to the directory */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
ret = IsMachineProtected (mono_string_chars (path));
#else
ret = IsProtected (path, (S_IWGRP | S_IWOTH));
@@@ -896,7 -895,7 +896,7 @@@ ves_icall_Mono_Security_Cryptography_Ke
MONO_ARCH_SAVE_REGS;
/* no one, but the user, should have access to the directory */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
ret = IsUserProtected (mono_string_chars (path));
#else
ret = IsProtected (path, (S_IRGRP | S_IWGRP | S_IXGRP | S_IROTH | S_IWOTH | S_IXOTH));
@@@ -913,7 -912,7 +913,7 @@@ ves_icall_Mono_Security_Cryptography_Ke
MONO_ARCH_SAVE_REGS;
/* read/write to owner, read to everyone else */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
ret = ProtectMachine (mono_string_chars (path));
#else
ret = Protect (path, (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH), (S_IXUSR | S_IXGRP | S_IXOTH));
@@@ -930,7 -929,7 +930,7 @@@ ves_icall_Mono_Security_Cryptography_Ke
MONO_ARCH_SAVE_REGS;
/* read/write to user, no access to everyone else */
- #ifdef PLATFORM_WIN32
+ #ifdef HOST_WIN32
ret = ProtectUser (mono_string_chars (path));
#else
ret = Protect (path, (S_IRUSR | S_IWUSR), S_IXUSR);
--
mono
More information about the Pkg-mono-svn-commits
mailing list