public override string[] Execute(ParsedArgs args) { Amass forestInfo = new Amass(); Forest currentForest = forestInfo.GetForestObject(); return(new string[] { currentForest.Name }); }
public override string[] Execute(ParsedArgs args) { try { Amass forestInfo = new Amass(); Forest currentForest = forestInfo.GetForestObject(); return(new string[] { currentForest.Name }); } catch (Exception e) { return(new string[] { "[X] Failure to enumerate info - " + e }); } }
public override string[] Execute(ParsedArgs args) { Amass forestDomains = new Amass(); Forest theCurrentForest = forestDomains.GetForestObject(); DomainCollection forestDomainList = theCurrentForest.Domains; List <string> result = new List <string>(); foreach (Domain internalDomain in forestDomainList) { result.Add(internalDomain.Name); } return(result.ToArray()); }
public override string[] Execute(ParsedArgs args) { try { Amass forestDomains = new Amass(); Forest theCurrentForest = forestDomains.GetForestObject(); DomainCollection forestDomainList = theCurrentForest.Domains; List <string> result = new List <string>(); foreach (Domain internalDomain in forestDomainList) { result.Add(internalDomain.Name); } return(result.ToArray()); } catch (Exception e) { return(new string[] { "[X] Failure to enumerate info - " + e }); } }