Display console link name as display name

This commit is contained in:
idk
2021-12-04 00:29:39 -05:00
parent 0a62ba9d4e
commit ba7c89f5ef

View File

@ -70,7 +70,7 @@ func (cc *ClientConfig) PrintCommand() string {
exesuffix = ".exe"
}
if cc.Command == nil || *cc.Command == "" {
return fmt.Sprintf("clientApp.0.args=%s%s%s -shellservice.name \"%s\" -shellservice.displayname \"%s\" %s\n", CIP, *cc.Command, exesuffix, *cc.ClientName, *cc.ClientDisplayName, *cc.ClientName, cc.PrintCommandArgs())
return fmt.Sprintf("clientApp.0.args=%s%s%s -shellservice.name \"%s\" -shellservice.displayname \"%s\" %s\n", CIP, *cc.Command, exesuffix, *cc.ClientName, *cc.ClientDisplayName, cc.PrintCommandArgs())
}
name := strings.Split(*cc.Command, " ")[0]
return fmt.Sprintf("clientApp.0.args=%s%s%s -shellservice.name \"%s\" -shellservice.displayname \"%s\" %s\n", CIP, name, exesuffix, *cc.ClientName, *cc.ClientDisplayName, cc.PrintCommandArgs())