mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 23:12:56 +00:00
Implement the ANSI stub EncryptFileA
svn path=/trunk/; revision=27713
This commit is contained in:
parent
1a9fa20283
commit
10ceb1dc62
1 changed files with 20 additions and 9 deletions
|
@ -561,19 +561,17 @@ BOOL WINAPI DecryptFileA(LPCSTR lpFileName, DWORD dwReserved)
|
||||||
{
|
{
|
||||||
UNICODE_STRING FileName;
|
UNICODE_STRING FileName;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
BOOL ret = FALSE;
|
BOOL ret;
|
||||||
|
|
||||||
FileName.Buffer = NULL;
|
|
||||||
|
|
||||||
Status = RtlCreateUnicodeStringFromAsciiz(&FileName, lpFileName);
|
Status = RtlCreateUnicodeStringFromAsciiz(&FileName, lpFileName);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
SetLastError(RtlNtStatusToDosError(Status));
|
SetLastError(RtlNtStatusToDosError(Status));
|
||||||
goto cleanup;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = DecryptFileW(FileName.Buffer, dwReserved);
|
ret = DecryptFileW(FileName.Buffer, dwReserved);
|
||||||
|
|
||||||
cleanup:
|
|
||||||
if (FileName.Buffer != NULL)
|
if (FileName.Buffer != NULL)
|
||||||
RtlFreeUnicodeString(&FileName);
|
RtlFreeUnicodeString(&FileName);
|
||||||
return ret;
|
return ret;
|
||||||
|
@ -590,15 +588,28 @@ BOOL WINAPI EncryptFileW(LPCWSTR lpFileName)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @unimplemented
|
* @implemented
|
||||||
*/
|
*/
|
||||||
BOOL WINAPI EncryptFileA(LPCSTR lpFileName)
|
BOOL WINAPI EncryptFileA(LPCSTR lpFileName)
|
||||||
{
|
{
|
||||||
DPRINT1("%s() not implemented!\n", __FUNCTION__);
|
UNICODE_STRING FileName;
|
||||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
NTSTATUS Status;
|
||||||
|
BOOL ret;
|
||||||
|
|
||||||
|
Status = RtlCreateUnicodeStringFromAsciiz(&FileName, lpFileName);
|
||||||
|
if (!NT_SUCCESS(Status))
|
||||||
|
{
|
||||||
|
SetLastError(RtlNtStatusToDosError(Status));
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ret = EncryptFileW(FileName.Buffer);
|
||||||
|
|
||||||
|
if (FileName.Buffer != NULL)
|
||||||
|
RtlFreeUnicodeString(&FileName);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
BOOL WINAPI ConvertSecurityDescriptorToStringSecurityDescriptorW(
|
BOOL WINAPI ConvertSecurityDescriptorToStringSecurityDescriptorW(
|
||||||
PSECURITY_DESCRIPTOR pSecurityDescriptor,
|
PSECURITY_DESCRIPTOR pSecurityDescriptor,
|
||||||
DWORD dword,
|
DWORD dword,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue