<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>16126</bug_id>
          
          <creation_ts>2026-01-07 07:45:09 +0000</creation_ts>
          <short_desc>Implement openat2 intercept in pseudo</short_desc>
          <delta_ts>2026-04-30 20:58:30 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>6</classification_id>
          <classification>Yocto Project Subprojects</classification>
          <product>Pseudo</product>
          <component>pseudo</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>6.0 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Khem Raj">raj.khem</reporter>
          <assigned_to name="Mark Hatle">mark.hatle</assigned_to>
          <cc>ccasciato</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>paul</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>richard.purdie</cc>
    
    <cc>yp.pseudo.watcher</cc>
    
    <cc>yp.watcher</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>103730</commentid>
    <comment_count>0</comment_count>
    <who name="Khem Raj">raj.khem</who>
    <bug_when>2026-01-07 07:45:09 +0000</bug_when>
    <thetext>openat2 in introduced in upcoming 2.43 release of glibc. Pseudo needs to be aware of this function and create an intercept for it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>103813</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2026-01-12 17:51:03 +0000</bug_when>
    <thetext>For tar on stream9 we need to intercept the syscall too:

https://git.yoctoproject.org/pseudo/tree/ports/linux/guts/syscall.c
https://git.yoctoproject.org/pseudo/tree/ports/linux/guts/syscall.c</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>103814</commentid>
    <comment_count>2</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2026-01-12 17:52:12 +0000</bug_when>
    <thetext>https://bugzilla.yoctoproject.org/show_bug.cgi?id=16117</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>103894</commentid>
    <comment_count>3</comment_count>
    <who name="Mark Hatle">mark.hatle</who>
    <bug_when>2026-01-15 00:55:56 +0000</bug_when>
    <thetext>psseudo master has a syscall intercept for SYS_openat2 that returns ENOSYS.  This should unblock immediate users.

Additionally, I&apos;ve adapted &apos;openat&apos; as a possible &apos;openat2&apos; implementation.

See: https://git.yoctoproject.org/pseudo/commit/?h=fray/master-wip&amp;id=022e103f0b1223fb6557d730471196cb2223ac27

This is a first version.  Once the function (not syscall) is mainstream, we&apos;ll likely want to have &apos;openat&apos; call &apos;openat2&apos;, as well and adjust it to pass through whatever openat2 interface glibc ends up with, but until then this SHOULD work and is good enough for testing purposes.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>103924</commentid>
    <comment_count>4</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2026-01-15 16:09:08 +0000</bug_when>
    <thetext>Lower to M+.

We&apos;ve got a patch to return ENOSYS for now and
there is a plan for a proper implementation.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>104982</commentid>
    <comment_count>5</comment_count>
    <who name="Paul Barker">paul</who>
    <bug_when>2026-04-08 09:45:48 +0000</bug_when>
    <thetext>Based on Zoltan&apos;s testing, it looks like we&apos;ll need full openat2() handling to build on Fedora 44 [1].

[1]: https://lore.kernel.org/openembedded-core/1b979680925d535d3cd344a8b736b8f862d52498.camel@pbarker.dev/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105060</commentid>
    <comment_count>6</comment_count>
    <who name="Paul Barker">paul</who>
    <bug_when>2026-04-13 15:45:51 +0000</bug_when>
    <thetext>We could use the gnulib openat2() implementation, relying on the fact that it calls openat() which we already handle.

https://gitweb.git.savannah.gnu.org/gitweb/?p=gnulib.git;a=blob;f=lib/openat2.c;h=2be62c921c5b90e8b0d528b33501ed3e1f2d7f92;hb=HEAD</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105079</commentid>
    <comment_count>7</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2026-04-15 13:52:24 +0000</bug_when>
    <thetext>https://git.yoctoproject.org/pseudo/log/?h=rpurdie/openat2 has a one idea of how we could make it work, I found and worked around the issue in Mark&apos;s implementation. I am worried there may be chroot issues with that change though.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105335</commentid>
    <comment_count>8</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2026-04-30 20:58:30 +0000</bug_when>
    <thetext>https://git.yoctoproject.org/pseudo/commit/?id=6533a536f93a13ec39e5fd42e3385798729e093f and following commit.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>