ROOTPLOIT
Server: LiteSpeed
System: Linux in-mum-web1878.main-hosting.eu 5.14.0-570.21.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jun 11 07:22:35 EDT 2025 x86_64
User: u435929562 (435929562)
PHP: 7.4.33
Disabled: system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Upload Files
File: //opt/golang/1.22.0/src/cmd/go/testdata/script/mod_list_dir.txt
[short] skip

# go list with path to directory should work

# populate go.sum
go get

env GO111MODULE=off
go list -f '{{.ImportPath}}' $GOROOT/src/math
stdout ^math$

env GO111MODULE=on
go list -f '{{.ImportPath}}' $GOROOT/src/math
stdout ^math$
go list -f '{{.ImportPath}}' .
stdout ^x$

go mod download rsc.io/[email protected]
go list -f '{{.ImportPath}}' $GOPATH/pkg/mod/rsc.io/[email protected]
stdout '^rsc.io/quote$'
go list -f '{{.ImportPath}}' $GOPATH/pkg/mod/rsc.io/[email protected]
stdout '^rsc.io/sampler$'
go get rsc.io/[email protected]
go list -f '{{.ImportPath}}' $GOPATH/pkg/mod/rsc.io/[email protected]
stdout '^rsc.io/sampler$'
! go list -f '{{.ImportPath}}' $GOPATH/pkg/mod/rsc.io/[email protected]
stderr 'outside main module or its selected dependencies'

-- go.mod --
module x
require rsc.io/quote v1.5.2

-- x.go --
package x

import _ "rsc.io/quote"