github-advanced-security[bot] commented on code in PR #3502:
URL: https://github.com/apache/dubbo-go/pull/3502#discussion_r3649333545


##########
tools/protoc-gen-go-triple/util/exec.go:
##########
@@ -28,9 +28,9 @@
        var cmd *exec.Cmd
        switch osEnv {
        case "darwin", "linux":
-               cmd = exec.Command("sh", "-c", arg) //NOSONAR
+               cmd = exec.Command("sh", "-c", arg)
        case "windows":
-               cmd = exec.Command("cmd.exe", "/c", arg) //NOSONAR
+               cmd = exec.Command("cmd.exe", "/c", arg)

Review Comment:
   ## SonarCloud / OS commands should not rely on PATH resolution
   
   <!--SONAR_ISSUE_KEY:AZ-XYoIUMs40bS2W-BT_-->Make sure the "PATH" variable 
only contains fixed, unwriteable directories. <p>See more on <a 
href="https://sonarcloud.io/project/issues?id=apache_dubbo-go&issues=AZ-XYoIUMs40bS2W-BT_&open=AZ-XYoIUMs40bS2W-BT_&pullRequest=3502";>SonarQube
 Cloud</a></p>
   
   [Show more 
details](https://github.com/apache/dubbo-go/security/code-scanning/73)



##########
tools/protoc-gen-go-triple/util/exec.go:
##########
@@ -28,9 +28,9 @@
        var cmd *exec.Cmd
        switch osEnv {
        case "darwin", "linux":
-               cmd = exec.Command("sh", "-c", arg) //NOSONAR
+               cmd = exec.Command("sh", "-c", arg)

Review Comment:
   ## SonarCloud / OS commands should not rely on PATH resolution
   
   <!--SONAR_ISSUE_KEY:AZ-XYoIUMs40bS2W-BT--->Make sure the "PATH" variable 
only contains fixed, unwriteable directories. <p>See more on <a 
href="https://sonarcloud.io/project/issues?id=apache_dubbo-go&issues=AZ-XYoIUMs40bS2W-BT-&open=AZ-XYoIUMs40bS2W-BT-&pullRequest=3502";>SonarQube
 Cloud</a></p>
   
   [Show more 
details](https://github.com/apache/dubbo-go/security/code-scanning/74)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to