Speakr is a personal, self-hosted web application designed for transcribing audio recordings
Python
Privacy notes: generalize the virtual-audio-device warning from Linux-only to all OS — same mechanism on macOS (BlackHole / Loopback), Windows (VB-Cable / Voicemeeter / Stereo Mix) and Linux (speakr_loopback): the virtual device shows up in navigator.mediaDevices.enumerateDevices alongside the real mic, and any site with mic permission can pick it and capture whatever's flowing through it under the regular mic-recording indicator, not the screen-sharing indicator; the previous wording made it sound like only the Linux PulseAudio module-virtual-source approach had this property which understated the risk for macOS and Windows users; new section has per-OS specifics (macOS: persistent driver, risk active only while Multi-Output Device is set as the system output; Windows: same pattern, while audio is routed through the cable; Linux: Chrome's monitor-source filter is what the module-virtual-source wrap explicitly undoes, runtime load/unload available) plus a single set of generalized mitigations (route through the virtual device only while recording, audit mic permissions, less obvious device name where possible)
Murtaza Nasir2f288ee1ad9c
diff --git a/templates/modals/system-audio-help-modal.html b/templates/modals/system-audio-help-modal.htmlindex da57acc1..72353c60 100644--- a/templates/modals/system-audio-help-modal.html+++ b/templates/modals/system-audio-help-modal.html@@ -224,19 +224,24 @@<div><div class="t-body-strong" style="margin-bottom: var(--sp-1); color: var(--text-warn, #d97706);"><i class="fas fa-triangle-exclamation"></i>- Linux virtual source (<code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code>)+ Virtual audio devices (BlackHole, VB-Cable, <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code>, etc.)</div><p class="t-body" style="color: var(--text-secondary);">- This is the one to think about. Chrome's filtering of PulseAudio monitor sources is a deliberate privacy protection. Without it, a malicious site with mic permission could silently record everything you're listening to (calls, sensitive content, private music) with no "screen sharing" indicator. The <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">module-virtual-source</code> wrap explicitly undoes that protection on your machine.+ This applies on every OS that uses a virtual audio device to route system audio into the browser. Once such a device exists on your machine, it shows up in <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">navigator.mediaDevices.enumerateDevices()</code> alongside your real microphone. Any site you've granted mic permission to can pick it and capture whatever audio is flowing through it, with the same "recording" indicator the browser shows for normal mic capture, not the "screen sharing" indicator.</p><p class="t-body" style="color: var(--text-secondary); margin-top: var(--sp-2);">- After the module is loaded, any site you've granted mic access to can enumerate <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code> and capture system audio through it.+ Per-OS specifics:</p>- <div class="t-body-strong" style="margin-top: var(--sp-2); margin-bottom: var(--sp-1);">Mitigations:</div><ul class="list-disc list-inside space-y-1 t-body" style="color: var(--text-secondary);">- <li><strong>Load on-demand.</strong> Don't add the <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">load-module</code> line to <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">~/.config/pulse/default.pa</code>. Run <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">pactl load-module …</code> before recording and <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">pactl unload-module module-virtual-source</code> after.</li>+ <li><strong>macOS (BlackHole / Loopback).</strong> The device is a permanently installed audio driver. The risk is active only while system audio is actually routed through it, i.e. while your output is set to the Multi-Output Device you configured. When you're not recording, switch the system output back to your normal device so nothing flows through BlackHole.</li>+ <li><strong>Windows (VB-Cable, Voicemeeter, Stereo Mix).</strong> Same pattern. The risk is active while audio is routed through the cable. Native "Share system audio" via the share dialog has no comparable exposure because nothing is routed through a virtual mic.</li>+ <li><strong>Linux (<code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code>).</strong> Chrome's filtering of "Monitor of …" sources is a deliberate privacy protection. The <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">module-virtual-source</code> wrap explicitly undoes that protection. Unlike macOS/Windows the device is a runtime PulseAudio module you can load and unload at will.</li>+ </ul>+ <div class="t-body-strong" style="margin-top: var(--sp-2); margin-bottom: var(--sp-1);">Mitigations (apply on every OS):</div>+ <ul class="list-disc list-inside space-y-1 t-body" style="color: var(--text-secondary);">+ <li><strong>Route system audio through the virtual device only while recording.</strong> On macOS, switch the system output back to your speakers / headphones after. On Windows, stop routing audio through the cable. On Linux, <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">pactl unload-module module-virtual-source</code> after, or don't put the <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">load-module</code> line in <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">default.pa</code>.</li><li><strong>Audit your mic permissions</strong> at <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">chrome://settings/content/microphone</code> and remove any site that doesn't strictly need it.</li>- <li><strong>Use a less obvious source name</strong> (e.g. <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">aux_in</code> instead of <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code>). Doesn't stop a determined enumerator but raises the bar.</li>+ <li><strong>Use a less obvious device name</strong> where you can choose one (e.g. <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">aux_in</code> instead of <code style="background: var(--bg-tertiary); padding: 0 4px; border-radius: 3px;">speakr_loopback</code> on Linux). Doesn't stop a determined enumerator but raises the bar.</li></ul></div>