<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 09:08:46 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[MONGOCRYPT-481] libmongocrypt needs mcr_dll_path which isn&apos;t implemented for all platforms</title>
                <link>https://jira.mongodb.org/browse/MONGOCRYPT-481</link>
                <project id="17481" key="MONGOCRYPT">Libmongocrypt</project>
                    <description>&lt;p&gt;libmongocrypt wants to know the path for a loaded library, seemingly to compare if a library is already loaded (_validate_csfle_singleton). It has an implementation for Windows, macOS, and Linux (though this uses dlinfo which is also available on Solaris and *BSD, AFAIK). However, if there is no implementation, then it&apos;ll fail the build with an error. I&apos;m building for AIX, so this is where I hit it.&lt;/p&gt;

&lt;p&gt;I looked into implementing this on AIX myself, but it did seem pretty tricky. dlopen returns an opaque ID that starts from zero and increments. Now, dladdr can be implemented in terms of calling a function that gets all loaded libraries (loadquery with L_GETINFO) and checking if the pointer is in their text/data ranges. However, dlinfo uses the value of dlopen, and the structure returned by loadquery that doesn&apos;t contain the IDs that libdl uses internally. I really want to avoid reaching into dynamic linker internals if I don&apos;t have to.&lt;/p&gt;

&lt;p&gt;An alternative might be to make it so that not having this function doesn&apos;t count as a hard error, and if not available, skip the validation logic. It&apos;d be a lot easier than trying to implement it on all platforms, and I don&apos;t think it&apos;s that critical anyways.&lt;/p&gt;</description>
                <environment></environment>
        <key id="2125727">MONGOCRYPT-481</key>
            <summary>libmongocrypt needs mcr_dll_path which isn&apos;t implemented for all platforms</summary>
                <type id="4" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14710&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="10300" iconUrl="https://jira.mongodb.org/images/icons/priorities/medium.svg">Unknown</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="13201">Fixed</resolution>
                                        <assignee username="kevin.albertson@mongodb.com">Kevin Albertson</assignee>
                                    <reporter username="calvin@cmpct.info">Calvin Buckley</reporter>
                        <labels>
                    </labels>
                <created>Tue, 30 Aug 2022 15:47:14 +0000</created>
                <updated>Mon, 4 Dec 2023 21:07:47 +0000</updated>
                            <resolved>Mon, 30 Oct 2023 20:10:44 +0000</resolved>
                                    <version>1.6.0-alpha0</version>
                                    <fixVersion>1.9.0</fixVersion>
                                    <component>C library</component>
                                        <votes>1</votes>
                                    <watches>5</watches>
                                                                                                                <comments>
                            <comment id="5924468" author="xgen-internal-githook" created="Mon, 4 Dec 2023 21:07:47 +0000"  >&lt;p&gt;Author: &lt;/p&gt;
{&apos;name&apos;: &apos;Calvin Buckley&apos;, &apos;email&apos;: &apos;calvin@cmpct.info&apos;, &apos;username&apos;: &apos;NattyNarwhal&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/MONGOCRYPT-603&quot; title=&quot;Don&amp;#39;t return a compile error if dll_path unsupported&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MONGOCRYPT-603&quot;&gt;&lt;del&gt;MONGOCRYPT-603&lt;/del&gt;&lt;/a&gt; Don&apos;t return a compile error if dll_path unsupported (#708)&lt;/p&gt;

&lt;ul&gt;
	&lt;li&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/MONGOCRYPT-481&quot; title=&quot;libmongocrypt needs mcr_dll_path which isn&amp;#39;t implemented for all platforms&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MONGOCRYPT-481&quot;&gt;&lt;del&gt;MONGOCRYPT-481&lt;/del&gt;&lt;/a&gt; Don&apos;t return a compile error if dll_path unsupported&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;This returns an error to the caller instead of a hard compile error.&lt;br/&gt;
The 34a6e9d585e4b8fd1c4f18ffa57a08a6f3338546 commit partially addressed&lt;br/&gt;
this, but this file wasn&apos;t touched by it&lt;/p&gt;

&lt;p&gt;This lets mongocrypt work on a platform without dll_path support, like&lt;br/&gt;
AIX, but CSFLE is untested.&lt;/p&gt;

&lt;p&gt;---------&lt;/p&gt;

&lt;p&gt;Co-authored-by: vector-of-bool &amp;lt;vectorofbool@gmail.com&amp;gt;&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/libmongocrypt/commit/4667d6ca888a465348fbc15fda459a652e67f39c&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/libmongocrypt/commit/4667d6ca888a465348fbc15fda459a652e67f39c&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="5846322" author="JIRAUSER1270934" created="Wed, 1 Nov 2023 15:05:06 +0000"  >&lt;p&gt;I think a simple patch might be:&lt;/p&gt;

&lt;p&gt;{{&lt;br/&gt;
diff --git a/src/mongocrypt-util.c b/src/mongocrypt-util.c&lt;br/&gt;
index 205ce26..958a870 100644&lt;br/&gt;
&amp;#8212; a/src/mongocrypt-util.c&lt;br/&gt;
+++ b/src/mongocrypt-util.c&lt;br/&gt;
@@ -90,7 +90,7 @@ current_module_result current_module_path(void) &lt;/p&gt;
{
         ret_str = mstr_copy_cstr(info.dli_fname);
     }
&lt;p&gt; #else&lt;br/&gt;
-#error &quot;Don&apos;t know how to get the module path on this platform&quot;&lt;br/&gt;
+    return (current_module_result)&lt;/p&gt;
{.path = NULL, .error = ENOSYS}
&lt;p&gt;;&lt;br/&gt;
 #endif&lt;br/&gt;
     return (current_module_result)&lt;/p&gt;
{.path = ret_str, .error = ret_error}
&lt;p&gt;;&lt;br/&gt;
 }&lt;br/&gt;
}}&lt;/p&gt;

&lt;p&gt;...but I don&apos;t know the repercussions for the CSFLE subsystem. I don&apos;t think it&apos;s strictly needed anyways?&lt;/p&gt;</comment>
                            <comment id="5844166" author="JIRAUSER1270934" created="Tue, 31 Oct 2023 19:07:42 +0000"  >&lt;p&gt;That patch isn&apos;t sufficient; `dladdr` is also called in &lt;span class=&quot;error&quot;&gt;&amp;#91;`mongo-util.c`&amp;#93;&lt;/span&gt;(&lt;a href=&quot;https://github.com/mongodb/libmongocrypt/blob/master/src/mongocrypt-util.c#L85&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/libmongocrypt/blob/master/src/mongocrypt-util.c#L85&lt;/a&gt;), called by &lt;span class=&quot;error&quot;&gt;&amp;#91;`_try_replace_dollar_origin`&amp;#93;&lt;/span&gt;(&lt;a href=&quot;https://github.com/mongodb/libmongocrypt/blob/master/src/mongocrypt.c#L433C13-L433C39&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/libmongocrypt/blob/master/src/mongocrypt.c#L433C13-L433C39&lt;/a&gt;).&lt;/p&gt;</comment>
                            <comment id="5833841" author="xgen-internal-githook" created="Mon, 30 Oct 2023 20:10:29 +0000"  >&lt;p&gt;Author: &lt;/p&gt;
{&apos;name&apos;: &apos;Kevin Albertson&apos;, &apos;email&apos;: &apos;kevin.albertson@mongodb.com&apos;, &apos;username&apos;: &apos;kevinAlbs&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/MONGOCRYPT-481&quot; title=&quot;libmongocrypt needs mcr_dll_path which isn&amp;#39;t implemented for all platforms&quot; class=&quot;issue-link&quot; data-issue-key=&quot;MONGOCRYPT-481&quot;&gt;&lt;del&gt;MONGOCRYPT-481&lt;/del&gt;&lt;/a&gt; Warn if `mcr_dll_path` not implemented (#705)&lt;/p&gt;

&lt;ul&gt;
	&lt;li&gt;add `mcr_dll_path_supported`&lt;/li&gt;
&lt;/ul&gt;


&lt;ul&gt;
	&lt;li&gt;warn if `mcr_dll_path` is not implemented&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/libmongocrypt/commit/34a6e9d585e4b8fd1c4f18ffa57a08a6f3338546&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/libmongocrypt/commit/34a6e9d585e4b8fd1c4f18ffa57a08a6f3338546&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</comment>
                            <comment id="5833840" author="mms-build@10gen.com" created="Mon, 30 Oct 2023 20:10:29 +0000"  >&lt;p&gt; &lt;a href=&quot;https://github.com/kevinAlbs&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;kevinAlbs&lt;/a&gt; merged a pull request (&lt;a href=&quot;https://github.com/mongodb/libmongocrypt/pull/705&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;MONGOCRYPT-481 Warn if `mcr_dll_path` not implemented&lt;/a&gt;) into the following branch:&lt;br/&gt;
                       master: &lt;a href=&quot;https://github.com/kevinAlbs/libmongocrypt/commit/34a6e9d585e4b8fd1c4f18ffa57a08a6f3338546&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;34a6e9d585e4b8fd1c4f18ffa57a08a6f3338546&lt;/a&gt;&lt;/p&gt;
</comment>
                            <comment id="5111615" author="JIRAUSER1257049" created="Fri, 13 Jan 2023 14:14:00 +0000"  >&lt;p&gt;This is blocking newer versions of libmongoc.&lt;/p&gt;

&lt;p&gt;The Reporter (Calvin Buckley) is the chief maintainer of PHP Community Edition (currently at 8.2) for the IBM i platform.&lt;/p&gt;

&lt;p&gt;WIBNI this could bump up a notch in priority &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.mongodb.org/images/icons/emoticons/biggrin.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt; thanks.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2510625">MONGOCRYPT-603</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                            <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_21553" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Quarter</customfieldname>
                        <customfieldvalues>
                                        <label>FY24Q3</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i0r3wo:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>