<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en" style="--code-editor-font: var(--default-mono-font, "GitLab Mono"), JetBrains Mono, Menlo, DejaVu Sans Mono, Liberation Mono, Consolas, Ubuntu Mono, Courier New, andale mono, lucida console, monospace;">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
<title>
GitLab
</title>
<style data-premailer="ignore" type="text/css">
a { color: #1068bf; }
</style>
<style>img {
max-width: 100%; height: auto;
}
body {
font-size: .875rem;
}
body {
-webkit-text-shadow: rgba(255,255,255,.01) 0 0 1px;
}
body {
font-family: "GitLab Sans",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Noto Sans",Ubuntu,Cantarell,"Helvetica Neue",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji"; font-size: inherit;
}
</style>
</head>
<body style="font-size: inherit; -webkit-text-shadow: rgba(255,255,255,.01) 0 0 1px; font-family: "GitLab Sans",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Noto Sans",Ubuntu,Cantarell,"Helvetica Neue",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";">
<div class="content">
<p class="details" style="font-style: italic; color: #626168;">
<a href="https://gitlab.rtems.org/Supernb">彤彤 李</a> created a merge request: <a href="https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1250">!1250</a>
</p>
<div class="branch">
Project:Branches: Supernb/rtems:issue-5420-pwdgrp-bsd to rtems/rtos/rtems:main
</div>
<div class="author">
Author: 彤彤 李
</div>
<div class="assignee">
Assignees:
</div>
<div class="reviewer">
Reviewers:
</div>
<div class="md gl-mt-5" style="position: relative; z-index: 1; color: #3a383f; word-wrap: break-word; margin-top: 1rem;">
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">This patch series reimplements the POSIX passwd and group entry APIs with BSD-licensed files-only implementations and removes the obsolete GPL passwd/group helper code.</p>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">Summary:</p>
<ul dir="auto" style="text-align: initial; list-style-type: disc; margin: 0 0 1rem; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Import the FreeBSD libc passwd/group sources under contrib as unchanged reference material.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Add a BSD-licensed RTEMS default passwd/group file initialization helper.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Reimplement the group database access routines in getgrent.c:
<ul style="list-style-type: circle; margin: 0; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrent_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrnam_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrgid_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrent()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrnam()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getgrgid()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">setgrent()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">endgrent()</li>
</ul>
</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Reimplement the passwd database access routines in getpwent.c:
<ul style="list-style-type: circle; margin: 0; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwent_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwnam_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwuid_r()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwent()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwnam()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">getpwuid()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">setpwent()</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">endpwent()</li>
</ul>
</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Preserve the existing RTEMS behavior of creating /etc, /etc/passwd, and /etc/group on demand.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Remove the obsolete pwdgrp.c and pwdgrp.h helper implementation.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Update getgroups() to handle the getpwuid_r() not-found case where the function returns zero with a NULL result pointer.</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">Update pwdgrp test documentation to refer to the new default file initialization helper.</li>
</ul>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">Validation performed on aarch64/zynqmp_qemu:</p>
<ul dir="auto" style="text-align: initial; list-style-type: disc; margin: 0 0 1rem; padding: 0;">
<li style="margin-top: 0; line-height: 1.6em; margin-left: 25px; padding-left: 3px;">./waf</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">psxpasswd01</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">pwdgrp01</li>
<li style="line-height: 1.6em; margin-left: 25px; padding-left: 3px;">pwdgrp02</li>
</ul>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">All tests passed.</p>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">The POSIX Users Guide documentation update mentioned in the issue is not included yet. I can add it to this MR after initial review, or submit it as a follow-up patch if preferred.</p>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">Generative AI:</p>
<p dir="auto" style="color: #3a383f; margin: 0 0 1rem;" align="initial">I used ChatGPT to help plan the implementation, review errors, draft commit messages, and prepare the merge request description. I manually applied the changes, built the tree, ran the tests, and reviewed the final patch series.</p>
<p dir="auto" style="color: #3a383f; margin: 0;" align="initial">Related to <a href="https://gitlab.rtems.org/rtems/rtos/rtems/-/issues/5420" title="Reimplement POSIX passwd and group Entry APIs" class="gfm gfm-issue" data-original="#5420" data-link="false" data-link-reference="false" data-issue="29414" data-project="26" data-iid="5420" data-namespace-path="rtems/rtos/rtems" data-project-path="rtems/rtos/rtems" data-issue-type="issue" data-container="body" data-placement="top" data-reference-type="issue" style="margin-top: 0;">#5420</a>.</p>
</div>
</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #626168;">
—
<br>
<a href="https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1250">View it on GitLab</a>.
<br>
You're receiving this email because of your account on <a target="_blank" rel="noopener noreferrer" href="https://gitlab.rtems.org">gitlab.rtems.org</a>. <a href="https://gitlab.rtems.org/-/sent_notifications/3-0d4q8flldfxgr3auf70lk294c/unsubscribe" target="_blank" rel="noopener noreferrer">Unsubscribe</a> from this thread · <a href="https://gitlab.rtems.org/-/profile/notifications" target="_blank" rel="noopener noreferrer" class="mng-notif-link">Manage all notifications</a> · <a href="https://gitlab.rtems.org/help" target="_blank" rel="noopener noreferrer" class="help-link">Help</a>
<span style="color: transparent; font-size: 0; display: none; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0;">
Notification message regarding https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1250 at 1779073084
</span>
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Merge request","url":"https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1250"}}</script>
</p>
</div>
</body>
</html>