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

Fix ACE_Stack_Trace potential buffer overflow. #859

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

likema
Copy link
Contributor

@likema likema commented Mar 5, 2019

No description provided.

@mitza-oci mitza-oci changed the title Fix ACE_Stack_Strace potential buffer overflow. Fix ACE_Stack_Trace potential buffer overflow. Mar 5, 2019
@likema likema force-pushed the stack-strace-buffer-overflow branch 2 times, most recently from cca348f to 2f8b3b4 Compare March 9, 2019 19:40
@likema likema force-pushed the stack-strace-buffer-overflow branch from 2f8b3b4 to 63cef3f Compare December 11, 2019 02:56
@jwillemsen
Copy link
Member

Please don't use force push, the big disadvantage is that we can't see what has changed, so it would require a full new review of a change, when you want to update the branch with all recent changes just merge master again into your branch

@likema
Copy link
Contributor Author

likema commented Dec 11, 2019

Please don't use force push, the big disadvantage is that we can't see what has changed, so it would require a full new review of a change, when you want to update the branch with all recent changes just merge master again into your branch

Sorry, OK

@@ -92,7 +92,7 @@ ACE_Stack_Trace::generate_trace (ssize_t starting_frame_offset, size_t num_frame
stack_syms = ::backtrace_symbols (stack, stack_size);

for (size_t i = starting_frame;
i < stack_size && num_frames > 0;
i < stack_size && num_frames > 0 && this->buflen_ < SYMBUFSIZ - 1;
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
i < stack_size && num_frames > 0 && this->buflen_ < SYMBUFSIZ - 1;
i < stack_size && num_frames > 0 && this->buflen_ < SYMBUFSIZ - 2;

Needs space for \n and \0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants