Commit Graph

735 Commits (5548ff6c71158170a36beba53b5e0097c627c8a1)

Author SHA1 Message Date
David Hall 5548ff6c71 Changed generic constraint on Write methods to struct instead of unmanaged 2019-04-10 13:11:06 -06:00
David Hall 7164c624b1 Added missing using statement 2019-04-10 13:10:35 -06:00
David Hall 124549d3f5 Added many new AdvApi32 methods 2019-04-10 12:13:59 -06:00
David Hall 9a76ee5597 Converted MarshalingStream references to NativeMemoryStream. 2019-04-10 12:13:28 -06:00
David Hall 34d48333d6 Corrected documentation errors 2019-04-10 11:28:19 -06:00
David Hall f0ce103165 Updated project file information 2019-04-09 15:20:49 -06:00
David Hall a4f85c035a Use NativeMemoryStream instead of MarshalingStream 2019-04-09 15:17:54 -06:00
David Hall f9c435ba9e Cleaned and added PrinciplePermissionAttribute tags to test methods requiring elevated privileges. 2019-04-09 14:30:10 -06:00
David Hall d007f1babd Lots of work on ACE handling 2019-04-09 11:46:44 -06:00
David Hall 37cceb6db5 BREAKING CHANGE: Removed methods that can cause unpredictable results due to ACE size differences. 2019-04-09 11:46:27 -06:00
David Hall 935fc50bf9 Updated tests for recent changes 2019-04-09 09:19:23 -06:00
David Hall 56abc66d2f Fixed bug in IsRunningAsAdmin when acting on token with TokenElevationTypeLimited flag. (#44) 2019-04-09 09:19:05 -06:00
David Hall 39264cc1ab Separated GetPropertyValue into 2 separate methods and removed type changing to prevent unintended consequences. 2019-04-09 09:16:59 -06:00
David Hall 6f62808fc5 New and additional tests 2019-04-08 19:45:25 -06:00
David Hall 578e84ac80 Updated to match changes to AclUI interfaces. 2019-04-08 19:45:04 -06:00
David Hall 73792290f6 Broke down and finally used an unsafe struct for this. 2019-04-08 19:44:08 -06:00
David Hall 83404805c7 Fixed so InvokeMethod would see private methods 2019-04-08 16:20:19 -06:00
David Hall f841eb3f84 Updated for stream implementation 2019-04-08 12:11:45 -06:00
David Hall 9ed6c463c7 WIP on new generic marshaler 2019-04-08 12:08:29 -06:00
David Hall b2906f6c9a Converted methods to PreserveSig model for all interfaces 2019-04-08 12:06:17 -06:00
David Hall 455f9971d2 Added resources tied to backwards compatible additions 2019-04-08 12:04:00 -06:00
David Hall 8cfcee658d Added much improved native memory stream implementation over MarshalingStream. Use NativeMemoryStream moving forward. It is saver and more function rich. 2019-04-08 12:03:20 -06:00
David Hall 65e1440ec0 Ensured that space in newly allocated memory is zeroed by default. Fixed handling of Size manipulation to zero out bytes added. (bug: it zeroed out everything) 2019-04-08 11:54:24 -06:00
David Hall 51edbded7c Added static Instance properties to IMemoryMethods implementations 2019-04-08 11:42:16 -06:00
David Hall 180dc255d8 Added 'Obsolete' attribute to push users to NativeMemoryStream 2019-04-08 11:41:26 -06:00
David Hall f18f91950d Fixes for handling null pointer and bool 2019-04-08 11:40:43 -06:00
David Hall 7bdc81796e Added AccessControlHelper.GetAces to enumerate aces on an acl. Added 'this' qualifier to turn methods into extension methods in AccessControlHelper. 2019-04-08 11:39:23 -06:00
David Hall a1837a70f5 Added ACCESS_ALLOWED_ACE.GetSid method to extract SafeSID value from structure. Added event structures. Made marshaler for PRIVILEGE_SET safer. Many additions to SafeSecurityDescriptor. 2019-04-08 11:38:00 -06:00
David Hall 9eea42368b Added functions: AccessCheck, AccessCheckByType, AccessCheckByTypeResultList, GetSecurityDescriptorGroup, GetSecurityDescriptorLength, GetSecurityDescriptorSacl, IsValidSecurityDescriptor. Provided helper overloads for GetAclInformation, GetPrivateObjectSecurity. Enhanced SafeHTOKEN class. 2019-04-08 11:35:40 -06:00
David Hall da6113c621 Cleaned up comments 2019-04-08 11:27:09 -06:00
David Hall a941609f2c Minor optimization of property Position use 2019-04-08 11:25:17 -06:00
David Hall 791e8af6a6 Added extension dump function for IntPtr 2019-04-08 11:24:19 -06:00
David Hall 427de28a0e Added ToStructure method with boundary checking. Cleaned and optimized code. 2019-03-26 21:03:39 -07:00
David Hall 0644bcedfb Minor reformatting 2019-03-26 21:02:27 -07:00
David Hall 3c40989527 Fixed Unicode bug in GetString 2019-03-25 17:40:06 -07:00
David Hall 178701d505 Added string handling to all Convert methods 2019-03-25 17:39:29 -07:00
David Hall dc83d5d0b4 Moved Dump, GetBytes and IntPtr operator to SafeAllocatedMemory base class. Added byte* and SafeBuffer operators to SafeAllocatedMemory. 2019-03-25 17:38:42 -07:00
David Hall 8281580a28 Added null checking to Contains method 2019-03-25 17:36:39 -07:00
David Hall 40155dc239 Added backwards compatible classes SafeBuffer, UnmanagedMemoryAccessor and UnmanagedMemoryStream for .NET 2.0 and 3.5. 2019-03-25 17:35:51 -07:00
David Hall f64c2b5e6b Added FindElementType extension method for Type. 2019-03-25 17:34:43 -07:00
David Hall 43a453fef9 Fixed bug in ToStructure where mishandled IntPtr. Added length checking to ToStringEnum. Changed length param on FillMemory to 'long' to work on 64-bit systems. 2019-03-25 17:34:03 -07:00
David Hall ef2f74cd83 Added allocation size handling to GetString and AllocString 2019-03-21 09:34:36 -06:00
David Hall b8fe8bdf89 Moved GetInheritanceSource helper to PInvoke project 2019-03-16 16:12:25 -06:00
David Hall 8560a43662 Completed work on unit test separation. All projects build. 2019-03-16 16:11:06 -06:00
David Hall 1a7a555de1 Separated out each unit test project so there is a 1:1 match between unit test project and assembly. Should simplify rebuilds on testing. 2019-03-16 10:28:15 -06:00
David Hall d7266f1919 Added ToArray and ToIEnum methods that work on Type value rather than generic type param. 2019-03-15 16:15:48 -06:00
David Hall ffb7879e3f Added AdvApi32 event log methods 2019-03-13 09:58:00 -06:00
David Hall 6a46bd4c96 Added null handler to MarshalToPtr 2019-03-13 09:56:21 -06:00
David Hall 72a2ceb50c Updated project versions to 2.3.5 2019-03-12 08:05:49 -06:00
David Hall 3d60a65f8d Added full support for cabinet.dll 2019-03-12 08:02:51 -06:00