Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non-TLS server crash when receiving a TLS connection #36

Closed
marcoacsilva opened this issue Sep 1, 2022 · 1 comment
Closed

Non-TLS server crash when receiving a TLS connection #36

marcoacsilva opened this issue Sep 1, 2022 · 1 comment

Comments

@marcoacsilva
Copy link

We noticed that when we have a Non-TLS server, if we receive a TLS Dial, the server crashes.

It doesn't happens if we do a Non-TLS Dial to a TLS server.

Log:
2022/09/01 13:17:00 Connection client [4] from 10.233.80.0:33315 accepted
2022/09/01 13:17:00 client 4 close()
2022/09/01 13:17:00 client 4 close() - stop reading from client
2022/09/01 13:17:00 client 4 close() - Abandon signal sent to processors
2022/09/01 13:17:00 client [4] request processors ended
2022/09/01 13:17:00 client [4] connection closed
panic: Expecting 0x30 as first byte, but got 0x16 instead

goroutine 69 [running]:
github.com/vjeantet/ldapserver.readTagAndLength(0x40d01f?, 0x40d01f?)
/go/pkg/mod/github.com/vjeantet/[email protected]/packet.go:89 +0x2b9
github.com/vjeantet/ldapserver.readLdapMessageBytes(0x30?)
/go/pkg/mod/github.com/vjeantet/[email protected]/packet.go:54 +0x45
github.com/vjeantet/ldapserver.readMessagePacket(0x30?)
/go/pkg/mod/github.com/vjeantet/[email protected]/packet.go:18 +0x1d
github.com/vjeantet/ldapserver.(*client).ReadPacket(0xc0001ffc00)
/go/pkg/mod/github.com/vjeantet/[email protected]/client.go:53 +0x29
github.com/vjeantet/ldapserver.(*client).serve(0xc0001ffc00)
/go/pkg/mod/github.com/vjeantet/[email protected]/client.go:117 +0x36f
created by github.com/vjeantet/ldapserver.(*Server).serve
/go/pkg/mod/github.com/vjeantet/[email protected]/server.go:110 +0x42d

@marcoacsilva
Copy link
Author

Duplicated. Same as #18

@marcoacsilva marcoacsilva closed this as not planned Won't fix, can't repro, duplicate, stale Sep 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant