NtSetSystemTime - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
#ifndef _NTEXAPI_H
#if (PHNT_MODE != PHNT_MODE_KERNEL)

NTSYSCALLAPI
NTSTATUS
NTAPI
NtSetSystemTime(
    _In_opt_ PLARGE_INTEGER SystemTime,
    _Out_opt_ PLARGE_INTEGER PreviousTime
    );

#endif
#endif

View code on GitHub
#ifndef _NTZWAPI_H

NTSYSCALLAPI
NTSTATUS
NTAPI
ZwSetSystemTime(
    _In_opt_ PLARGE_INTEGER SystemTime,
    _Out_opt_ PLARGE_INTEGER PreviousTime
    );

#endif

View code on GitHub

Function NtSetSystemTime sets system time. See NtQuerySystemTime for detailed information.

SystemTime

Pointer to LARGE_INTEGER contains UTC time to set.

PreviousTime

Optionally receives time before change.

Documented by

Requirements

Privilege: SE_SYSTEMTIME_PRIVILEGE

See also