New issue
Advanced search Search tips

Issue 619667 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Jun 2016
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: ----
Type: Bug-Security



Sign in to add a comment

Security: minijail - string tokenizing

Reported by eternalg...@gmail.com, Jun 13 2016

Issue description

VULNERABILITY DETAILS
source: https://chromium.googlesource.com/aosp/platform/external/minijail/+/master/minijail0.c

The above mentioned source uses the banned function strtok a lot.
Be cautious when using these functions. If you do use them, note that:

    These functions modify their first argument.
    These functions cannot be used on constant strings.
    The identity of the delimiting character is lost.
    The strtok() function uses a static buffer while parsing, so it's not thread safe.(buffer overflow)

I recommend you use strtok_s instead.
By using strtok_s the following changes will occur:

A new parameter, s1max, prevents strtok_s from storing outside of the string being tokenized. (The string being divided into tokens is both an input and output of the function since strtok_s stores null characters into the string.)

A new parameter, ptr, eliminates the static internal state that prevents strtok from being re-entrant (Subclause 1.1.12). (The ISO/IEC 9899 function wcstok and the ISO/IEC 9945 (POSIX) function strtok_r fix this problem identically.)



VERSION
Chrome Version: stable

 
Status: WontFix (was: Unconfirmed)
Hi -- This template is for reporting Chrome security vulnerabilities.  Looks like this pertains to Android ASOP.  You might try this for Android bugs: https://source.android.com/security/overview/updates-resources.html#report-issues
Project Member

Comment 2 by sheriffbot@chromium.org, Sep 20 2016

Labels: -Restrict-View-SecurityTeam
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 3 by sheriffbot@chromium.org, Oct 1 2016

This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 4 by sheriffbot@chromium.org, Oct 2 2016

This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: allpublic

Comment 6 by vapier@chromium.org, Jun 21 2018

Components: OS>Systems>Minijail

Sign in to add a comment