mirror of
https://github.com/peass-ng/PEASS-ng.git
synced 2026-07-30 23:50:27 -07:00
Fix unassigned out vars in OEM pipe check
This commit is contained in:
@@ -160,8 +160,14 @@ namespace winPEAS.Info.ServicesInfo
|
|||||||
var path = $"\\\\.\\pipe\\{pipeHint.Name}";
|
var path = $"\\\\.\\pipe\\{pipeHint.Name}";
|
||||||
var security = File.GetAccessControl(path);
|
var security = File.GetAccessControl(path);
|
||||||
string sddl = security.GetSecurityDescriptorSddlForm(AccessControlSections.All);
|
string sddl = security.GetSecurityDescriptorSddlForm(AccessControlSections.All);
|
||||||
bool worldWritable = pipeHint.CheckWorldWritable &&
|
string identity = string.Empty;
|
||||||
HasWorldWritableAce(security, out string identity, out string rights);
|
string rights = string.Empty;
|
||||||
|
bool worldWritable = false;
|
||||||
|
|
||||||
|
if (pipeHint.CheckWorldWritable)
|
||||||
|
{
|
||||||
|
worldWritable = HasWorldWritableAce(security, out identity, out rights);
|
||||||
|
}
|
||||||
|
|
||||||
string details = worldWritable
|
string details = worldWritable
|
||||||
? $"Named pipe '{pipeHint.Name}' ({pipeHint.Description}) is writable by {identity} ({rights})."
|
? $"Named pipe '{pipeHint.Name}' ({pipeHint.Description}) is writable by {identity} ({rights})."
|
||||||
|
|||||||
Reference in New Issue
Block a user