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

Add error handling for FTP TLS handshake #314

Merged
merged 1 commit into from
Jun 8, 2021
Merged

Add error handling for FTP TLS handshake #314

merged 1 commit into from
Jun 8, 2021

Conversation

hmcguinn
Copy link
Contributor

@hmcguinn hmcguinn commented Jun 1, 2021

This pull requests adds a check in modules/ftp/scanner.go for an error upon completing a TLS handshake.

@zakird
Copy link
Member

zakird commented Jun 6, 2021

This looks like it will prevent attempting to grab banner if the TLS handshake fails. I believe that this is the right thing to do since it's a TLS wrapped FTP session not running TLS after FTP has started. @codyprime can you confirm that this makes sense?

@zakird zakird requested a review from codyprime June 6, 2021 18:20
Copy link
Member

@zakird zakird left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM unless @codyprime flags something in the logic.

Copy link
Member

@codyprime codyprime left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me as well, thanks

@codyprime
Copy link
Member

This looks like it will prevent attempting to grab banner if the TLS handshake fails. I believe that this is the right thing to do since it's a TLS wrapped FTP session not running TLS after FTP has started. @codyprime can you confirm that this makes sense?

Yeah, I also believe this is the correct thing to do, since in this path TLS was requested for this scan. We should error out if we cannot establish a TLS connection.

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

Successfully merging this pull request may close these issues.

3 participants