peass-ng/PEASS-ng · error · NotV1SupportedException
Security settings are not available on Task Scheduler 1.0.
Error message
Security settings are not available on Task Scheduler 1.0.
What it means
V1 capability check inside RegisterTaskDefinition's createType switch: TaskCreation.DontAddPrincipalAce (and similar security-descriptor options) rely on SDDL-based security settings that the legacy Task Scheduler 1.0 API does not expose, so a NotV1SupportedException is thrown instead of registering with ignored security settings.
Source
Thrown at winPEAS/winPEASexe/winPEAS/TaskScheduler/TaskFolder.cs:566
definition.v1Task.SetAccountInformation(user.Name, cpwd.DangerousGetHandle());
break;
default:
throw new ArgumentOutOfRangeException(nameof(logonType), logonType, null);
}
definition.v1Task.SetFlags(flags);
switch (createType)
{
case TaskCreation.Create:
case TaskCreation.CreateOrUpdate:
case TaskCreation.Disable:
case TaskCreation.Update:
if (createType == TaskCreation.Disable)
definition.Settings.Enabled = false;
definition.V1Save(path);
break;
case TaskCreation.DontAddPrincipalAce:
throw new NotV1SupportedException("Security settings are not available on Task Scheduler 1.0.");
case TaskCreation.IgnoreRegistrationTriggers:
throw new NotV1SupportedException("Registration triggers are not available on Task Scheduler 1.0.");
case TaskCreation.ValidateOnly:
throw new NotV1SupportedException("XML validation not available on Task Scheduler 1.0.");
default:
throw new ArgumentOutOfRangeException(nameof(createType), createType, null);
}
return new Task(TaskService, definition.v1Task);
}
/// <summary>
/// Applies access control list (ACL) entries described by a <see cref="TaskSecurity"/> object to the file described by the current <see cref="TaskFolder"/> object.
/// </summary>
/// <param name="taskSecurity">A <see cref="TaskSecurity"/> object that describes an access control list (ACL) entry to apply to the current folder.</param>
public void SetAccessControl([NotNull] TaskSecurity taskSecurity) { taskSecurity.Persist(this); }
/// <summary>
/// Sets the security descriptor for the folder. Not available to Task Scheduler 1.0.View on GitHub (pinned to 53fb989abc)
Solutions
- Register with TaskCreation.Create or CreateOrUpdate on V1 and adjust the .job file security outside the API
- Run on Task Scheduler 2.0+ where SDDL security settings are supported
Defensive patterns
Strategy: fallback
When it happens
Trigger: Thrown at winPEAS/winPEASexe/winPEAS/TaskScheduler/TaskFolder.cs:566 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of peass-ng/PEASS-ng@53fb989abc (2026-09-02).
Data as JSON: /api/errors/273211798a5e4d5c.
Report an issue: GitHub.