RFR: 8277489: Rewrite JAAS UnixLoginModule with FFM [v7]

Weijun Wang weijun at openjdk.org
Wed Jan 7 21:18:33 UTC 2026


On Wed, 7 Jan 2026 08:35:57 GMT, Per Minborg <pminborg at openjdk.org> wrote:

>> Weijun Wang has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   must have username; more comments
>
> src/jdk.security.auth/share/classes/com/sun/security/auth/module/UnixSystem.java line 88:
> 
>> 86:             = (ValueLayout) LINKER.canonicalLayouts().get("size_t");
>> 87: 
>> 88:     private static final StructLayout capturedStateLayout = Linker.Option.captureStateLayout();
> 
> Would it be a good idea to use capitalized names for immutable static fields in all places in the class? E.g., `CAPTURED_STATE_LAYOUT` here.

Sure, I can use `CAPTURED_STATE_LAYOUT` and `ERRNO_HANDLE`. Do you also want me to capitalize those `MethodHandle`s, `pw_xyz_layout`, and `pw_xyz_offset`? I'll be happy to do so if we want to keep this tradition. I was looking into `HBShaper` and it's mixed there. The `jextract` output puts every constant behind a method and avoids this awkwardness.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/28931#discussion_r2670096071


More information about the build-dev mailing list