Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix #677: Exception in async_server_base/async_connection during port scanning (nmap)#678

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation

vovams
Copy link

Fix for issue#677.

During a port scanasync_server_base::handle_accept() may be called while the connection is not properly established. No error code is passed tohandel_accept() (i.e.!!ec == false) but the subsequent call toasync_connection::start() ->stream_handler::remote_endpoint() ->asio::basic_socket::remote_endpoint() fails with an exception.

My fix is to add error checking by usingasio::basic_socket::remote_endpoint(asio::error_code&) overload instream_handler::remote_endpoint() and passing the error toasync_connection::start().

Since i had to change signature ofstream_handler::remote_endpoint(), i added a new overload with old signature and behavior to keep any code which uses it working.

@glynos
Copy link
Member

@vovams sorry, the 0.12-release branch is not correct. Please apply the PR to the0.13-release branch. The PR looks good, though.

@glynosglynos closed thisAug 10, 2016
@vovams
Copy link
Author

I can adapt the fix for 0.13, but what about 0.12? I wanted to merge the fix into it because i am using 0.12 in my project.

@deanberris
Copy link
Member

@glynos -- Do you think it's OK for us to pull this in then release a 0.12.1 to address just this issue?

@glynos
Copy link
Member

@deanberris -- No, we agreed that some changes in 0.12 were mistakenly added, and reverted those changes in 0.13. We are slow to release a 0.13 version, but I think this should be a part of it.

@deanberris
Copy link
Member

Okay, SGTM.

@vovams
Copy link
Author

I do not know your release plans, but branch 0.12-release currently contains some other fixes as well. For example,79aaa62, because of which i had to switch my project from cpp-netlib-0.12.0-final tag to the tip of 0.12-release. So a bugfix release might be useful.

Anyway, i opened new pull request for 0.13-release:#679.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@vovams@glynos@deanberris

[8]ページ先頭

©2009-2025 Movatter.jp