This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git


The following commit(s) were added to refs/heads/asf-site by this push:
     new 46292c2d Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 
docs: a9640bad1a75997db85ec7cbd0d06c9a0049e68a
46292c2d is described below

commit 46292c2dce989589edf40bb719ac8c7fe59164c6
Author: Brennan Ashton <[email protected]>
AuthorDate: Thu May 18 00:11:34 2023 +0000

    Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 
a9640bad1a75997db85ec7cbd0d06c9a0049e68a
---
 content/docs/10.0.0/index.html                     |   2 +-
 content/docs/10.0.0/searchindex.js                 |   2 +-
 content/docs/10.0.1/index.html                     |   2 +-
 content/docs/10.0.1/searchindex.js                 |   2 +-
 content/docs/10.1.0/index.html                     |   2 +-
 content/docs/10.1.0/searchindex.js                 |   2 +-
 content/docs/10.2.0/index.html                     |   2 +-
 content/docs/10.2.0/searchindex.js                 |   2 +-
 content/docs/10.3.0/index.html                     |   2 +-
 content/docs/10.3.0/searchindex.js                 |   2 +-
 content/docs/11.0.0/index.html                     |   2 +-
 content/docs/11.0.0/searchindex.js                 |   2 +-
 content/docs/12.0.0/index.html                     |   2 +-
 content/docs/12.0.0/searchindex.js                 |   2 +-
 content/docs/12.1.0/index.html                     |   2 +-
 content/docs/12.1.0/searchindex.js                 |   2 +-
 .../_sources/reference/user/10_filesystem.rst.txt  |  56 +++++++++++++++
 content/docs/latest/genindex.html                  |   6 ++
 content/docs/latest/index.html                     |   2 +-
 content/docs/latest/introduction/licensing.html    |  32 +++++++++
 content/docs/latest/objects.inv                    | Bin 46207 -> 46321 bytes
 .../docs/latest/reference/user/10_filesystem.html  |  80 +++++++++++++++++++++
 content/docs/latest/searchindex.js                 |   2 +-
 content/feed.xml                                   |   4 +-
 24 files changed, 194 insertions(+), 20 deletions(-)

diff --git a/content/docs/10.0.0/index.html b/content/docs/10.0.0/index.html
index 03f52558..d4df3771 100644
--- a/content/docs/10.0.0/index.html
+++ b/content/docs/10.0.0/index.html
@@ -133,7 +133,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller 
environments, the primary governing standards in NuttX are Posix and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:10</p>
+<p>Last Updated: 18 May 23 at 00:09</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/10.0.0/searchindex.js 
b/content/docs/10.0.0/searchindex.js
index 5413a095..c486ae8c 100644
--- a/content/docs/10.0.0/searchindex.js
+++ b/content/docs/10.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
diff --git a/content/docs/10.0.1/index.html b/content/docs/10.0.1/index.html
index 25978d08..2a506553 100644
--- a/content/docs/10.0.1/index.html
+++ b/content/docs/10.0.1/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller 
environments, the primary governing standards in NuttX are Posix and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:11</p>
+<p>Last Updated: 18 May 23 at 00:09</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/10.0.1/searchindex.js 
b/content/docs/10.0.1/searchindex.js
index 3e9b5e5c..c486ae8c 100644
--- a/content/docs/10.0.1/searchindex.js
+++ b/content/docs/10.0.1/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
diff --git a/content/docs/10.1.0/index.html b/content/docs/10.1.0/index.html
index 0062ba7f..b4fc7284 100644
--- a/content/docs/10.1.0/index.html
+++ b/content/docs/10.1.0/index.html
@@ -148,7 +148,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:11</p>
+<p>Last Updated: 18 May 23 at 00:09</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/10.1.0/searchindex.js 
b/content/docs/10.1.0/searchindex.js
index a2cdb6b6..09f69065 100644
--- a/content/docs/10.1.0/searchindex.js
+++ b/content/docs/10.1.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/10.2.0/index.html b/content/docs/10.2.0/index.html
index 88075d17..dadb831a 100644
--- a/content/docs/10.2.0/index.html
+++ b/content/docs/10.2.0/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:11</p>
+<p>Last Updated: 18 May 23 at 00:09</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/10.2.0/searchindex.js 
b/content/docs/10.2.0/searchindex.js
index b172d836..06ee7145 100644
--- a/content/docs/10.2.0/searchindex.js
+++ b/content/docs/10.2.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/10.3.0/index.html b/content/docs/10.3.0/index.html
index 88075d17..dadb831a 100644
--- a/content/docs/10.3.0/index.html
+++ b/content/docs/10.3.0/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:11</p>
+<p>Last Updated: 18 May 23 at 00:09</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/10.3.0/searchindex.js 
b/content/docs/10.3.0/searchindex.js
index fb491ded..3e841a05 100644
--- a/content/docs/10.3.0/searchindex.js
+++ b/content/docs/10.3.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/11.0.0/index.html b/content/docs/11.0.0/index.html
index 88075d17..e02f0895 100644
--- a/content/docs/11.0.0/index.html
+++ b/content/docs/11.0.0/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:11</p>
+<p>Last Updated: 18 May 23 at 00:10</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/11.0.0/searchindex.js 
b/content/docs/11.0.0/searchindex.js
index 0adbb4f1..188b1b91 100644
--- a/content/docs/11.0.0/searchindex.js
+++ b/content/docs/11.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/12.0.0/index.html b/content/docs/12.0.0/index.html
index 2729b89d..4ac08833 100644
--- a/content/docs/12.0.0/index.html
+++ b/content/docs/12.0.0/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:12</p>
+<p>Last Updated: 18 May 23 at 00:10</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/12.0.0/searchindex.js 
b/content/docs/12.0.0/searchindex.js
index 516a379f..3090acd9 100644
--- a/content/docs/12.0.0/searchindex.js
+++ b/content/docs/12.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/12.1.0/index.html b/content/docs/12.1.0/index.html
index 5b73f52c..640df176 100644
--- a/content/docs/12.1.0/index.html
+++ b/content/docs/12.1.0/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:12</p>
+<p>Last Updated: 18 May 23 at 00:10</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/12.1.0/searchindex.js 
b/content/docs/12.1.0/searchindex.js
index b9508ed4..1e1f3707 100644
--- a/content/docs/12.1.0/searchindex.js
+++ b/content/docs/12.1.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/foc","components/drivers/character/index","components/drivers/character
 [...]
\ No newline at end of file
diff --git a/content/docs/latest/_sources/reference/user/10_filesystem.rst.txt 
b/content/docs/latest/_sources/reference/user/10_filesystem.rst.txt
index d567797d..65a736d2 100644
--- a/content/docs/latest/_sources/reference/user/10_filesystem.rst.txt
+++ b/content/docs/latest/_sources/reference/user/10_filesystem.rst.txt
@@ -574,3 +574,59 @@ are two conditions where ``mmap()`` can be supported:
     -  ``ENODEV`` - The underlying file-system of the specified file does
        not support memory mapping.
 
+Fdsan
+---------------
+FD (file descriptor) is widely used in system software development,
+and almost all implementations of posix os (including nuttx) use FD as an 
index.
+the value of fd needs to be allocated starting from the minimum available 
value of 3, and each process has a copy,
+so the same fd value is very easy to reuse in the program.
+
+In multi threaded or multi process environments without address isolation,
+If the ownership, global variables, and competition relationships of fd are 
not properly handled,
+there may be issues with fd duplication or accidental closure.
+Further leading to the following issues, which are difficult to troubleshoot.
+
+1. Security vulnerability: the fd we wrote is not the expected fd and will be 
accessed by hackers to obtain data
+2. Program exceptions or crashes: write or read fd failures, and program logic 
errors
+3. The structured file XML or database is damaged: the data format written to 
the database is not the expected format.
+
+The implementation principle of fdsan is based on the implementation of Android
+https://android.googlesource.com/platform/bionic/+/master/docs/fdsan.md
+
+
+.. c:function:: uint64_t android_fdsan_create_owner_tag(enum 
android_fdsan_owner_type type, uint64_t tag);
+
+  Create an owner tag with the specified type and least significant 56 bits of 
tag.
+
+  :param type: See the ANDROID_* definitions in include/android/fdsan.h.
+
+     -  ``ANDROID_FDSAN_OWNER_TYPE_FILE`` - FILE
+     -  ``ANDROID_FDSAN_OWNER_TYPE_DIR`` - DIR
+     -  ``ANDROID_FDSAN_OWNER_TYPE_UNIQUE_FD`` - android::base::unique_fd
+     -  ``ANDROID_FDSAN_OWNER_TYPE_SQLITE`` - sqlite-owned file descriptors
+     -  ``ANDROID_FDSAN_OWNER_TYPE_FILEINPUTSTREAM`` - java.io.FileInputStream
+     -  ``ANDROID_FDSAN_OWNER_TYPE_FILEOUTPUTSTREAM`` - 
java.io.FileOutputStream
+     -  ``ANDROID_FDSAN_OWNER_TYPE_RANDOMACCESSFILE`` - 
java.io.RandomAccessFile
+     -  ``ANDROID_FDSAN_OWNER_TYPE_PARCELFILEDESCRIPTOR`` - 
android.os.ParcelFileDescriptor
+     -  ``ANDROID_FDSAN_OWNER_TYPE_ART_FDFILE`` - ART FdFile
+     -  ``ANDROID_FDSAN_OWNER_TYPE_DATAGRAMSOCKETIMPL`` - 
java.net.DatagramSocketImpl
+     -  ``ANDROID_FDSAN_OWNER_TYPE_SOCKETIMPL`` - java.net.SocketImpl
+     -  ``ANDROID_FDSAN_OWNER_TYPE_ZIPARCHIVE`` - libziparchive's ZipArchive
+
+  :param tag: least significant 56 bits of tag. Typically, it is a pointer to 
the object/structure where fd is located
+
+.. c:function:: void android_fdsan_exchange_owner_tag(int fd, uint64_t 
expected_tag,  uint64_t new_tag);
+
+  Exchange a file descriptor's tag. Logs and aborts if the fd's tag does not 
match expected_tag.
+
+  :param fd: The fd we want to protect
+  :param expected_tag: The tag corresponding to the current fd
+  :param new_tag: A new tag for fd binding
+
+.. c:function:: int android_fdsan_close_with_tag(int fd, uint64_t tag);
+
+  Close a file descriptor with a tag, and resets the tag to 0. Logs and aborts 
if the tag is incorrect.
+
+  :param fd: The fd we want to protect.
+  :param tag: The tag corresponding to the current fd.
+  :return: Consistent with the return value of close.
diff --git a/content/docs/latest/genindex.html 
b/content/docs/latest/genindex.html
index 47f5a344..ff4d2351 100644
--- a/content/docs/latest/genindex.html
+++ b/content/docs/latest/genindex.html
@@ -194,9 +194,15 @@
       <li><a href="glossary.html#term-ADC"><strong>ADC</strong></a>
 </li>
       <li><a href="glossary.html#term-AIC"><strong>AIC</strong></a>
+</li>
+      <li><a 
href="reference/user/10_filesystem.html#c.android_fdsan_close_with_tag">android_fdsan_close_with_tag
 (C function)</a>
+</li>
+      <li><a 
href="reference/user/10_filesystem.html#c.android_fdsan_create_owner_tag">android_fdsan_create_owner_tag
 (C function)</a>
 </li>
   </ul></td>
   <td style="width: 33%; vertical-align: top;"><ul>
+      <li><a 
href="reference/user/10_filesystem.html#c.android_fdsan_exchange_owner_tag">android_fdsan_exchange_owner_tag
 (C function)</a>
+</li>
       <li><a 
href="reference/os/time_clock.html#c.archname_timer_initialize">archname_timer_initialize
 (C function)</a>
 </li>
       <li><a href="glossary.html#term-ARP"><strong>ARP</strong></a>
diff --git a/content/docs/latest/index.html b/content/docs/latest/index.html
index 63be5a23..f112939f 100644
--- a/content/docs/latest/index.html
+++ b/content/docs/latest/index.html
@@ -149,7 +149,7 @@ by following these <a class="reference internal" 
href="contributing/documentatio
 <section id="nuttx-documentation">
 <h1>NuttX Documentation<a class="headerlink" href="#nuttx-documentation" 
title="Permalink to this headline"></a></h1>
 <p>NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller 
environments, the primary governing standards in NuttX are POSIX and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).</p>
-<p>Last Updated: 17 May 23 at 00:12</p>
+<p>Last Updated: 18 May 23 at 00:10</p>
 <div class="toctree-wrapper compound">
 <p class="caption" role="heading"><span class="caption-text">Table of 
Contents</span></p>
 <ul class="current">
diff --git a/content/docs/latest/introduction/licensing.html 
b/content/docs/latest/introduction/licensing.html
index 54ad3bac..92d0150a 100644
--- a/content/docs/latest/introduction/licensing.html
+++ b/content/docs/latest/introduction/licensing.html
@@ -8547,6 +8547,38 @@ ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES 
OR ANY DAMAGES
 WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
 ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+
+libs/libc/regcomp.c
+libs/libc/regerror.c
+libs/libc/regexec.c
+libs/libc/tre.h
+libs/libc/tre-mem.c
+include/regex.h
+======================
+musl as a whole is licensed under the following standard MIT license:
+
+----------------------------------------------------------------------
+Copyright © 2005-2014 Rich Felker, et al.
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+&quot;Software&quot;), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+----------------------------------------------------------------------
 </pre>
 </section>
 </section>
diff --git a/content/docs/latest/objects.inv b/content/docs/latest/objects.inv
index f7adbb30..12153b8a 100644
Binary files a/content/docs/latest/objects.inv and 
b/content/docs/latest/objects.inv differ
diff --git a/content/docs/latest/reference/user/10_filesystem.html 
b/content/docs/latest/reference/user/10_filesystem.html
index 4532080f..a240b9c1 100644
--- a/content/docs/latest/reference/user/10_filesystem.html
+++ b/content/docs/latest/reference/user/10_filesystem.html
@@ -133,6 +133,7 @@
 <li class="toctree-l5"><a class="reference internal" 
href="#standard-string-operations">Standard String Operations</a></li>
 <li class="toctree-l5"><a class="reference internal" 
href="#pipes-and-fifos">Pipes and FIFOs</a></li>
 <li class="toctree-l5"><a class="reference internal" 
href="#mmap-and-execute-in-place-xip"><code class="docutils literal 
notranslate"><span class="pre">mmap()</span></code> and eXecute In Place 
(XIP)</a></li>
+<li class="toctree-l5"><a class="reference internal" 
href="#fdsan">Fdsan</a></li>
 </ul>
 </li>
 </ul>
@@ -851,6 +852,85 @@ not support memory mapping.</p></li>
 </dl>
 </dd></dl>
 
+</section>
+<section id="fdsan">
+<h3>Fdsan<a class="headerlink" href="#fdsan" title="Permalink to this 
headline"></a></h3>
+<p>FD (file descriptor) is widely used in system software development,
+and almost all implementations of posix os (including nuttx) use FD as an 
index.
+the value of fd needs to be allocated starting from the minimum available 
value of 3, and each process has a copy,
+so the same fd value is very easy to reuse in the program.</p>
+<p>In multi threaded or multi process environments without address isolation,
+If the ownership, global variables, and competition relationships of fd are 
not properly handled,
+there may be issues with fd duplication or accidental closure.
+Further leading to the following issues, which are difficult to 
troubleshoot.</p>
+<ol class="arabic simple">
+<li><p>Security vulnerability: the fd we wrote is not the expected fd and will 
be accessed by hackers to obtain data</p></li>
+<li><p>Program exceptions or crashes: write or read fd failures, and program 
logic errors</p></li>
+<li><p>The structured file XML or database is damaged: the data format written 
to the database is not the expected format.</p></li>
+</ol>
+<p>The implementation principle of fdsan is based on the implementation of 
Android
+<a class="reference external" 
href="https://android.googlesource.com/platform/bionic/+/master/docs/fdsan.md";>https://android.googlesource.com/platform/bionic/+/master/docs/fdsan.md</a></p>
+<dl class="c function">
+<dt class="sig sig-object c" id="c.android_fdsan_create_owner_tag">
+<span class="n"><span class="pre">uint64_t</span></span><span class="w"> 
</span><span class="sig-name descname"><span class="n"><span 
class="pre">android_fdsan_create_owner_tag</span></span></span><span 
class="sig-paren">(</span><span class="k"><span 
class="pre">enum</span></span><span class="w"> </span><span class="n"><span 
class="pre">android_fdsan_owner_type</span></span><span class="w"> </span><span 
class="n"><span class="pre">type</span></span>, <span class="n"><span 
class="pre">uin [...]
+<dd><p>Create an owner tag with the specified type and least significant 56 
bits of tag.</p>
+<dl class="field-list simple">
+<dt class="field-odd">Parameters</dt>
+<dd class="field-odd"><ul class="simple">
+<li><p><strong>type</strong> – <p>See the ANDROID_* definitions in 
include/android/fdsan.h.</p>
+<ul>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_FILE</span></code> - FILE</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_DIR</span></code> - DIR</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_UNIQUE_FD</span></code> - 
android::base::unique_fd</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_SQLITE</span></code> - sqlite-owned file 
descriptors</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_FILEINPUTSTREAM</span></code> - 
java.io.FileInputStream</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_FILEOUTPUTSTREAM</span></code> - 
java.io.FileOutputStream</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_RANDOMACCESSFILE</span></code> - 
java.io.RandomAccessFile</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_PARCELFILEDESCRIPTOR</span></code> - 
android.os.ParcelFileDescriptor</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_ART_FDFILE</span></code> - ART 
FdFile</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_DATAGRAMSOCKETIMPL</span></code> - 
java.net.DatagramSocketImpl</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_SOCKETIMPL</span></code> - 
java.net.SocketImpl</p></li>
+<li><p><code class="docutils literal notranslate"><span 
class="pre">ANDROID_FDSAN_OWNER_TYPE_ZIPARCHIVE</span></code> - libziparchive’s 
ZipArchive</p></li>
+</ul>
+</p></li>
+<li><p><strong>tag</strong> – least significant 56 bits of tag. Typically, it 
is a pointer to the object/structure where fd is located</p></li>
+</ul>
+</dd>
+</dl>
+</dd></dl>
+
+<dl class="c function">
+<dt class="sig sig-object c" id="c.android_fdsan_exchange_owner_tag">
+<span class="kt"><span class="pre">void</span></span><span class="w"> 
</span><span class="sig-name descname"><span class="n"><span 
class="pre">android_fdsan_exchange_owner_tag</span></span></span><span 
class="sig-paren">(</span><span class="kt"><span 
class="pre">int</span></span><span class="w"> </span><span class="n"><span 
class="pre">fd</span></span>, <span class="n"><span 
class="pre">uint64_t</span></span><span class="w"> </span><span class="n"><span 
class="pre">expected_tag</span></s [...]
+<dd><p>Exchange a file descriptor’s tag. Logs and aborts if the fd’s tag does 
not match expected_tag.</p>
+<dl class="field-list simple">
+<dt class="field-odd">Parameters</dt>
+<dd class="field-odd"><ul class="simple">
+<li><p><strong>fd</strong> – The fd we want to protect</p></li>
+<li><p><strong>expected_tag</strong> – The tag corresponding to the current 
fd</p></li>
+<li><p><strong>new_tag</strong> – A new tag for fd binding</p></li>
+</ul>
+</dd>
+</dl>
+</dd></dl>
+
+<dl class="c function">
+<dt class="sig sig-object c" id="c.android_fdsan_close_with_tag">
+<span class="kt"><span class="pre">int</span></span><span class="w"> 
</span><span class="sig-name descname"><span class="n"><span 
class="pre">android_fdsan_close_with_tag</span></span></span><span 
class="sig-paren">(</span><span class="kt"><span 
class="pre">int</span></span><span class="w"> </span><span class="n"><span 
class="pre">fd</span></span>, <span class="n"><span 
class="pre">uint64_t</span></span><span class="w"> </span><span class="n"><span 
class="pre">tag</span></span><span clas [...]
+<dd><p>Close a file descriptor with a tag, and resets the tag to 0. Logs and 
aborts if the tag is incorrect.</p>
+<dl class="field-list simple">
+<dt class="field-odd">Parameters</dt>
+<dd class="field-odd"><ul class="simple">
+<li><p><strong>fd</strong> – The fd we want to protect.</p></li>
+<li><p><strong>tag</strong> – The tag corresponding to the current fd.</p></li>
+</ul>
+</dd>
+<dt class="field-even">Returns</dt>
+<dd class="field-even"><p>Consistent with the return value of close.</p>
+</dd>
+</dl>
+</dd></dl>
+
 </section>
 </section>
 </section>
diff --git a/content/docs/latest/searchindex.js 
b/content/docs/latest/searchindex.js
index 8a7a40a5..8370369d 100644
--- a/content/docs/latest/searchindex.js
+++ b/content/docs/latest/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","applications/wapi/commands","applications/wapi/index","applications/wapi/wireless","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drive
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","applications/nsh/builtin","applications/nsh/commands","applications/nsh/config","applications/nsh/customizing","applications/nsh/index","applications/nsh/installation","applications/nsh/login","applications/nsh/nsh","applications/wapi/commands","applications/wapi/index","applications/wapi/wireless","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drive
 [...]
\ No newline at end of file
diff --git a/content/feed.xml b/content/feed.xml
index 1ef0b007..5e6d2a78 100644
--- a/content/feed.xml
+++ b/content/feed.xml
@@ -5,8 +5,8 @@
     <description></description>
     <link>/</link>
     <atom:link href="/feed.xml" rel="self" type="application/rss+xml"/>
-    <pubDate>Wed, 17 May 2023 00:13:31 +0000</pubDate>
-    <lastBuildDate>Wed, 17 May 2023 00:13:31 +0000</lastBuildDate>
+    <pubDate>Thu, 18 May 2023 00:11:31 +0000</pubDate>
+    <lastBuildDate>Thu, 18 May 2023 00:11:31 +0000</lastBuildDate>
     <generator>Jekyll v4.3.2</generator>
     
       <item>


Reply via email to