<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/internal/sanitizers.h, branch v3_4_9</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>Prefix asan_poison_object with rb</title>
<updated>2024-12-19T14:14:34+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2024-12-18T17:01:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a58675386c10f4183116056bc0cf289548883ac0'/>
<id>a58675386c10f4183116056bc0cf289548883ac0</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Export asan_poison_object</title>
<updated>2024-12-19T14:14:34+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2024-12-13T18:46:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a72717675f0ddaa07127ea2fa25b7c1e271fdbce'/>
<id>a72717675f0ddaa07127ea2fa25b7c1e271fdbce</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Make asan_poison_object poison the whole slot</title>
<updated>2024-12-19T14:14:34+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2024-12-11T17:18:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=c37bdfa5311be0aa8503b995299fb9547cede0a6'/>
<id>c37bdfa5311be0aa8503b995299fb9547cede0a6</id>
<content type='text'>
This change poisons the whole slot of the object rather than just the flags.
This allows ASAN to find any reads/writes into the slot after it has been
freed.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This change poisons the whole slot of the object rather than just the flags.
This allows ASAN to find any reads/writes into the slot after it has been
freed.
</pre>
</div>
</content>
</entry>
<entry>
<title>Detect ASAN when using older GCC versions</title>
<updated>2024-12-16T22:11:36+00:00</updated>
<author>
<name>Alan Wu</name>
<email>alanwu@ruby-lang.org</email>
</author>
<published>2024-12-16T22:11:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=2102fe32ff8191ad51001daf57a1ed09a1ebc824'/>
<id>2102fe32ff8191ad51001daf57a1ed09a1ebc824</id>
<content type='text'>
Newer GCCs have __has_feature and older ones have
__SANITIZE_ADDRESS__[1]. Relevant since ASAN with GCC 11 on the popular
Ubuntu Jammy failed to build previously.

[1]: https://gcc.gnu.org/onlinedocs/gcc-4.8.0/cpp/Common-Predefined-Macros.html
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Newer GCCs have __has_feature and older ones have
__SANITIZE_ADDRESS__[1]. Relevant since ASAN with GCC 11 on the popular
Ubuntu Jammy failed to build previously.

[1]: https://gcc.gnu.org/onlinedocs/gcc-4.8.0/cpp/Common-Predefined-Macros.html
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix ATTRIBUTE_NO_ADDRESS_SAFETY_ANALYSIS for MSAN</title>
<updated>2024-12-04T19:29:24+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2024-11-29T21:08:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=3c91a1e5fda8b3e03348dc533dcf292a598f1f77'/>
<id>3c91a1e5fda8b3e03348dc533dcf292a598f1f77</id>
<content type='text'>
There's no case for when RUBY_MSAN_ENABLED, so the macro ends up doing
nothing when it should instead have __attribute__((__no_sanitize__("memory"))).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There's no case for when RUBY_MSAN_ENABLED, so the macro ends up doing
nothing when it should instead have __attribute__((__no_sanitize__("memory"))).
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix extra semicolon outside of a function in `NO_SANITIZE`</title>
<updated>2024-10-08T14:29:49+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2024-10-08T12:25:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8ba2c3109c0f80f285b8db2fed10d8f5f026c208'/>
<id>8ba2c3109c0f80f285b8db2fed10d8f5f026c208</id>
<content type='text'>
```
internal/sanitizers.h:57:26: error: ISO C does not allow extra ‘;’ outside of a function [-Wpedantic]
   57 |     COMPILER_WARNING_PUSH; \
      |                          ^
```

and so many.

Remove semicolons following pragma, and repeat the given declaration
at the end to consume a semicolon following the macro call.  As many
`NO_SANITIZE` calls including bigdecimal that is a gem have a trailing
semicolon, it was not able to move the semicolon inside `NO_SANITIZE`.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
```
internal/sanitizers.h:57:26: error: ISO C does not allow extra ‘;’ outside of a function [-Wpedantic]
   57 |     COMPILER_WARNING_PUSH; \
      |                          ^
```

and so many.

Remove semicolons following pragma, and repeat the given declaration
at the end to consume a semicolon following the macro call.  As many
`NO_SANITIZE` calls including bigdecimal that is a gem have a trailing
semicolon, it was not able to move the semicolon inside `NO_SANITIZE`.
</pre>
</div>
</content>
</entry>
<entry>
<title>Unpoison page-&gt;freelist before trying to assert on it</title>
<updated>2024-09-23T00:11:54+00:00</updated>
<author>
<name>KJ Tsanaktsidis</name>
<email>kj@kjtsanaktsidis.id.au</email>
</author>
<published>2024-09-21T11:11:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=02b36f75721aa61d48e3031c71695837d7a8a410'/>
<id>02b36f75721aa61d48e3031c71695837d7a8a410</id>
<content type='text'>
Otherwise trying to deref the pointer can cause an ASAN crash, even
though the only reason we're dereferencing it is so that we can assert
on it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Otherwise trying to deref the pointer can cause an ASAN crash, even
though the only reason we're dereferencing it is so that we can assert
on it.
</pre>
</div>
</content>
</entry>
<entry>
<title>[DOC] Unify Doxygen formats (#10285)</title>
<updated>2024-03-19T17:59:25+00:00</updated>
<author>
<name>Takashi Kokubun</name>
<email>takashikkbn@gmail.com</email>
</author>
<published>2024-03-19T17:59:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=cbcb2d46fc6d0971084b41df987480d2d9355328'/>
<id>cbcb2d46fc6d0971084b41df987480d2d9355328</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Extract imemo functions from gc.c into imemo.c</title>
<updated>2024-02-22T16:35:09+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2024-02-21T20:48:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=e65315a7253c58ad2d3bbf5482723976ff3d6640'/>
<id>e65315a7253c58ad2d3bbf5482723976ff3d6640</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Mark asan fake stacks during machine stack marking</title>
<updated>2024-01-18T22:55:12+00:00</updated>
<author>
<name>KJ Tsanaktsidis</name>
<email>ktsanaktsidis@zendesk.com</email>
</author>
<published>2024-01-17T00:45:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=61da90c1b8d5c9a62d429ef66f000117eca675b3'/>
<id>61da90c1b8d5c9a62d429ef66f000117eca675b3</id>
<content type='text'>
ASAN leaves a pointer to the fake frame on the stack; we can use the
__asan_addr_is_in_fake_stack API to work out the extent of the fake
stack and thus mark any VALUEs contained therein.

[Bug #20001]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
ASAN leaves a pointer to the fake frame on the stack; we can use the
__asan_addr_is_in_fake_stack API to work out the extent of the fake
stack and thus mark any VALUEs contained therein.

[Bug #20001]
</pre>
</div>
</content>
</entry>
</feed>
