File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1028,7 +1028,7 @@ func GetUniqueID() string {
10281028 if ! ok {
10291029 continue
10301030 }
1031- if strings .EqualFold (engineStr , "Checkmarx Developer Assist" ) {
1031+ if strings .EqualFold (engineStr , "Checkmarx One Assist" ) {
10321032 isAllowed = true
10331033 break
10341034 }
@@ -1048,7 +1048,14 @@ func GetUniqueID() string {
10481048 logger .PrintIfVerbose ("Failed to get user: " + err .Error ())
10491049 return ""
10501050 }
1051- uniqueID = uuid .New ().String () + "_" + currentUser .Username
1051+ username := currentUser .Username
1052+ username = strings .TrimSpace (username )
1053+ logger .PrintIfVerbose ("Username to be used for unique id: " + username )
1054+ if strings .Contains (username , "\\ " ) {
1055+ username = strings .Split (username , "\\ " )[1 ]
1056+ }
1057+ uniqueID = uuid .New ().String () + "_" + username
1058+
10521059 logger .PrintIfVerbose ("Unique id: " + uniqueID )
10531060 viper .Set (commonParams .UniqueIDConfigKey , uniqueID )
10541061 configFilePath , _ := configuration .GetConfigFilePath ()
You can’t perform that action at this time.
0 commit comments