I'm not sure this would be very straightforward at all as an engineering matter, but you could embed a microcontroller that looks for a certain pattern and then performs modifications indicated by that pattern.<p>An example could be a password, followed by something like a search and replace buffer. In Python pseudocode, something like<p><pre><code> for i, v in enumerate(ram):
if v == b'\x9eP"\xcb\xde\x8fP\xcf':
for i2, v2 in enumerate(ram):
if v2 == ram[i+8]:
ram[i2] = ram[i+16]
break
</code></pre>
Then if you could get the machine to internally store a string containing that password followed by a substitution, it could perform the specified substitution automatically elsewhere (in a database? in a kernel data structure?), having some desired side effect.<p>Of course, the microcontroller wouldn't actually need to be able to interpret Python code, and could be a very tiny, slow, and small one. (And it would have to be powered by the bus that the RAM device itself was plugged into!!)<p>Another similar thing would be, instead of a search-and-replace, giving patterns and saying "copy from after whatever matches this, to whatever matches that", so that you could get a data leak across users, compartments, VMs, etc., where the attacking unprivileged one would set up a buffer containing the "receive" string and then wait for that buffer to get filled with a copy of the location in RAM containing the "transmit" string.