Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
40427f1a
Commit
40427f1a
authored
Mar 30, 2012
by
Hans Leidekker
Committed by
Alexandre Julliard
Mar 30, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
advapi32: Return a fake security descriptor from CreatePrivateObjectSecurity.
Based on a patch by Robert Shearman.
parent
88a2620b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
2 deletions
+39
-2
security.c
dlls/advapi32/security.c
+39
-2
No files found.
dlls/advapi32/security.c
View file @
40427f1a
...
...
@@ -5105,16 +5105,53 @@ BOOL WINAPI CreatePrivateObjectSecurity(
HANDLE
Token
,
PGENERIC_MAPPING
GenericMapping
)
{
FIXME
(
"%p %p %p %d %p %p - stub
\n
"
,
ParentDescriptor
,
CreatorDescriptor
,
NewDescriptor
,
IsDirectoryObject
,
Token
,
GenericMapping
);
SECURITY_DESCRIPTOR_RELATIVE
*
relative
;
DWORD
needed
,
offset
;
BYTE
*
buffer
;
FIXME
(
"%p %p %p %d %p %p - returns fake SECURITY_DESCRIPTOR
\n
"
,
ParentDescriptor
,
CreatorDescriptor
,
NewDescriptor
,
IsDirectoryObject
,
Token
,
GenericMapping
);
needed
=
sizeof
(
SECURITY_DESCRIPTOR_RELATIVE
);
needed
+=
sizeof
(
sidWorld
);
needed
+=
sizeof
(
sidWorld
);
needed
+=
WINE_SIZE_OF_WORLD_ACCESS_ACL
;
needed
+=
WINE_SIZE_OF_WORLD_ACCESS_ACL
;
if
(
!
(
buffer
=
HeapAlloc
(
GetProcessHeap
(),
0
,
needed
)))
return
FALSE
;
relative
=
(
SECURITY_DESCRIPTOR_RELATIVE
*
)
buffer
;
if
(
!
InitializeSecurityDescriptor
(
relative
,
SECURITY_DESCRIPTOR_REVISION
))
{
HeapFree
(
GetProcessHeap
(),
0
,
buffer
);
return
FALSE
;
}
relative
->
Control
|=
SE_SELF_RELATIVE
;
offset
=
sizeof
(
SECURITY_DESCRIPTOR_RELATIVE
);
memcpy
(
buffer
+
offset
,
&
sidWorld
,
sizeof
(
sidWorld
)
);
relative
->
Owner
=
offset
;
offset
+=
sizeof
(
sidWorld
);
memcpy
(
buffer
+
offset
,
&
sidWorld
,
sizeof
(
sidWorld
)
);
relative
->
Group
=
offset
;
offset
+=
sizeof
(
sidWorld
);
GetWorldAccessACL
(
(
ACL
*
)(
buffer
+
offset
)
);
relative
->
Dacl
=
offset
;
offset
+=
WINE_SIZE_OF_WORLD_ACCESS_ACL
;
GetWorldAccessACL
(
(
ACL
*
)(
buffer
+
offset
)
);
relative
->
Sacl
=
offset
;
*
NewDescriptor
=
relative
;
return
TRUE
;
}
BOOL
WINAPI
DestroyPrivateObjectSecurity
(
PSECURITY_DESCRIPTOR
*
ObjectDescriptor
)
{
FIXME
(
"%p - stub
\n
"
,
ObjectDescriptor
);
HeapFree
(
GetProcessHeap
(),
0
,
*
ObjectDescriptor
);
return
TRUE
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment