mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-09-07 05:22:27 +00:00
Remove unused fields from tlsPoller
This commit is contained in:
@@ -30,12 +30,9 @@ type tlsPoller struct {
|
|||||||
extension *api.Extension
|
extension *api.Extension
|
||||||
procfs string
|
procfs string
|
||||||
pidToNamespace sync.Map
|
pidToNamespace sync.Map
|
||||||
id int64
|
|
||||||
isClosed bool
|
isClosed bool
|
||||||
protoIdentifier *api.ProtoIdentifier
|
protoIdentifier *api.ProtoIdentifier
|
||||||
isTapTarget bool
|
isTapTarget bool
|
||||||
clients []api.TcpReader
|
|
||||||
servers []api.TcpReader
|
|
||||||
origin api.Capture
|
origin api.Capture
|
||||||
createdAt time.Time
|
createdAt time.Time
|
||||||
}
|
}
|
||||||
@@ -144,6 +141,7 @@ func (p *tlsPoller) handleTlsChunk(chunk *tlsChunk, extension *api.Extension,
|
|||||||
func(r *tlsReader) {
|
func(r *tlsReader) {
|
||||||
p.closeReader(key, r)
|
p.closeReader(key, r)
|
||||||
},
|
},
|
||||||
|
chunk.IsRequest(),
|
||||||
p,
|
p,
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -279,7 +277,9 @@ func (p *tlsPoller) logTls(chunk *tlsChunk, ip net.IP, port uint16) {
|
|||||||
chunk.Recorded, chunk.Len, chunk.Start, str, hex.EncodeToString(chunk.Data[0:chunk.Recorded]))
|
chunk.Recorded, chunk.Len, chunk.Start, str, hex.EncodeToString(chunk.Data[0:chunk.Recorded]))
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) Close() {}
|
func (p *tlsPoller) Close() {
|
||||||
|
// TODO: Implement
|
||||||
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) CloseOtherProtocolDissectors(protocol *api.Protocol) {
|
func (p *tlsPoller) CloseOtherProtocolDissectors(protocol *api.Protocol) {
|
||||||
// TODO: Implement
|
// TODO: Implement
|
||||||
@@ -290,19 +290,19 @@ func (p *tlsPoller) AddClient(reader api.TcpReader) {}
|
|||||||
func (p *tlsPoller) AddServer(reader api.TcpReader) {}
|
func (p *tlsPoller) AddServer(reader api.TcpReader) {}
|
||||||
|
|
||||||
func (p *tlsPoller) GetClients() []api.TcpReader {
|
func (p *tlsPoller) GetClients() []api.TcpReader {
|
||||||
return p.clients
|
return []api.TcpReader{}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) GetServers() []api.TcpReader {
|
func (p *tlsPoller) GetServers() []api.TcpReader {
|
||||||
return p.servers
|
return []api.TcpReader{}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) GetClient(index int) api.TcpReader {
|
func (p *tlsPoller) GetClient(index int) api.TcpReader {
|
||||||
return p.clients[index]
|
return &tlsReader{}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) GetServer(index int) api.TcpReader {
|
func (p *tlsPoller) GetServer(index int) api.TcpReader {
|
||||||
return p.servers[index]
|
return &tlsReader{}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) GetOrigin() api.Capture {
|
func (p *tlsPoller) GetOrigin() api.Capture {
|
||||||
@@ -326,9 +326,7 @@ func (p *tlsPoller) GetIsClosed() bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) GetId() int64 {
|
func (p *tlsPoller) GetId() int64 {
|
||||||
return p.id
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *tlsPoller) SetId(id int64) {
|
func (p *tlsPoller) SetId(id int64) {}
|
||||||
p.id = id
|
|
||||||
}
|
|
||||||
|
@@ -26,7 +26,7 @@ type tlsReader struct {
|
|||||||
reqResMatcher api.RequestResponseMatcher
|
reqResMatcher api.RequestResponseMatcher
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewTlsReader(key string, doneHandler func(r *tlsReader), stream api.TcpStream) api.TcpReader {
|
func NewTlsReader(key string, doneHandler func(r *tlsReader), isClient bool, stream api.TcpStream) api.TcpReader {
|
||||||
return &tlsReader{
|
return &tlsReader{
|
||||||
key: key,
|
key: key,
|
||||||
chunks: make(chan api.TlsChunk, 1),
|
chunks: make(chan api.TlsChunk, 1),
|
||||||
|
Reference in New Issue
Block a user