RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 890225 - new_line gets truncated in merge_group_entries
Summary: new_line gets truncated in merge_group_entries
Keywords:
Status: CLOSED DUPLICATE of bug 890222
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: shadow-utils
Version: 6.3
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: 6.5
Assignee: Tomas Mraz
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks: 947775 947782
TreeView+ depends on / blocked
 
Reported: 2012-12-25 22:00 UTC by Brad Hubbard
Modified: 2014-06-04 14:15 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-04 14:15:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Add one to new_line_length to accommodate new line char (493 bytes, patch)
2012-12-25 22:00 UTC, Brad Hubbard
no flags Details | Diff

Description Brad Hubbard 2012-12-25 22:00:52 UTC
Created attachment 669050 [details]
Add one to new_line_length to accommodate new line char

Description of problem:
Whilst investigating BZ 890222 I discovered a problem in the following code.

Allowance is made for the terminating NULL in new_line_len but not the newline char that is added when the two lines are concatenated. The result is new_line ends up one character short.

314 /* Concatenate the 2 lines */
315 new_line_len = strlen (gr1->line) + strlen (gr2->line) +1;
316 new_line = (char *)malloc ((new_line_len + 1) * sizeof(char*));
317 if (NULL == new_line) {
318 errno = ENOMEM;
319 return NULL;
320 }
321 snprintf(new_line, new_line_len, "%s\n%s", gr1->line, gr2->line);
322 new_line[new_line_len] = '\0';

Patch attached.


Version-Release number of selected component (if applicable):
shadow-utils-4.1.4.2-13.el6.x86_64

Additional info:
Reported and patch submitted upstream.

https://alioth.debian.org/tracker/index.php?func=detail&aid=313942&group_id=30580&atid=411478

Comment 1 RHEL Program Management 2013-10-14 00:07:00 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.

Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.

Comment 2 Tomas Mraz 2014-06-04 14:15:02 UTC
We will fix this with one patch.

*** This bug has been marked as a duplicate of bug 890222 ***


Note You need to log in before you can comment on or make changes to this bug.