mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-07-09 14:24:04 +00:00
Remove MIZU_GLOBAL_GOLANG_PATH
environment variable
This commit is contained in:
parent
2293e4346f
commit
b0340db8bc
@ -293,15 +293,6 @@ func startTlsTapper(extension *api.Extension, outputItems chan *api.OutputChanne
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// A quick way to instrument Go `crypto/tls` using executable path - used for debuging and troubleshooting
|
|
||||||
//
|
|
||||||
if os.Getenv("MIZU_GLOBAL_GOLANG_PATH") != "" {
|
|
||||||
if err := tls.GlobalGolangTapPath(os.Getenv("MIZU_GLOBAL_GOLANG_PATH")); err != nil {
|
|
||||||
tlstapper.LogError(err)
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var emitter api.Emitter = &api.Emitting{
|
var emitter api.Emitter = &api.Emitting{
|
||||||
AppStats: &diagnose.AppStats,
|
AppStats: &diagnose.AppStats,
|
||||||
OutputChannel: outputItems,
|
OutputChannel: outputItems,
|
||||||
|
@ -79,10 +79,6 @@ func (t *TlsTapper) GlobalGolangTap(procfs string, pid string) error {
|
|||||||
return t.tapGolangPid(procfs, uint32(_pid), api.UNKNOWN_NAMESPACE)
|
return t.tapGolangPid(procfs, uint32(_pid), api.UNKNOWN_NAMESPACE)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (t *TlsTapper) GlobalGolangTapPath(exePath string) error {
|
|
||||||
return t.tapGolangPath(exePath)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (t *TlsTapper) AddSsllibPid(procfs string, pid uint32, namespace string) error {
|
func (t *TlsTapper) AddSsllibPid(procfs string, pid uint32, namespace string) error {
|
||||||
sslLibrary, err := findSsllib(procfs, pid)
|
sslLibrary, err := findSsllib(procfs, pid)
|
||||||
|
|
||||||
@ -217,20 +213,6 @@ func (t *TlsTapper) tapGolangPid(procfs string, pid uint32, namespace string) er
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (t *TlsTapper) tapGolangPath(exePath string) error {
|
|
||||||
hooks := golangHooks{}
|
|
||||||
|
|
||||||
if err := hooks.installUprobes(&t.bpfObjects, exePath); err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
|
|
||||||
logger.Log.Infof("Tapping TLS (Golang: %v)", exePath)
|
|
||||||
|
|
||||||
t.golangHooksStructs = append(t.golangHooksStructs, hooks)
|
|
||||||
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func LogError(err error) {
|
func LogError(err error) {
|
||||||
var e *errors.Error
|
var e *errors.Error
|
||||||
if errors.As(err, &e) {
|
if errors.As(err, &e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user