91.1 Camera Privacy

20200811

Usually an LED lights up when a computer camera is in use to provide a visual cue that the camera is capturing data. Until recently the control of the LED was software accessible and the camera could be on even without the LED, raising a privacy concern—malicious software could capture video from you computer (even through visiting a web page on a web browser) and stream the video remotely without indication. Newer laptops, for example the Lenovo X1 Yoga, have cameras whereby the indicator light is directly hardware controlled and is not settable by software. You should determine whether your camera LED is software controllable and if so, take measures to occlude the camera when not in use. Some computers provide a manual camera shade but many don’t.

The uvcdynctrl command from the uvcdynctrl package is a command line tool to control the camera LED and other camera settings through the libwebcam library. We can use this to determine if the camera LED is settable.

First identify the camera. On a computer with two cameras, one an infrared and the other the usual webcam, the --list optionof uvcdynctrl will list both cameras:

$ uvcdynctrl --list
Listing available devices:
  video0   Integrated IR Camera: Integrate
    Media controller device: /dev/media0
[...]
  video1   Integrated Camera: Integrated C
    Media controller device: /dev/media1
[...]

The two devices are video0 and video1 with the latter as the usual webcam. To see if the camera LED is controlable list the available controls:

$ uvcdynctrl --clist --device=video1
Listing available controls for device video1:
  Brightness
  Contrast
  Saturation
  Hue
  White Balance Temperature, Auto
  Gamma
  Power Line Frequency
  White Balance Temperature
  Sharpness
  Backlight Compensation
  Exposure, Auto
  Exposure (Absolute)
  Exposure, Auto Priority

If the list contains an LED mode then the LED is controlable. If not then privacy is likely protected and the LED will likely be switched on in hardware whenever the camera is on.

An older Logitech QuickCam Pro 9000 (WebCam), for example, has a software controllable LED. To avoid the LED giving away the fact that the camera is recording, which may actually be useful a covert security situation, the following commands can be utilised:

$ sudo uvcdynctrl -i /usr/share/uvcdynctrl/data/046d/logitech.xml

$ uvcdynctrl --clist            # Available controls
$ uvcdynctrl -s 'LED1 Mode' 0   # LED off
$ uvcdynctrl -s 'LED1 Mode' 1   # LED on
$ uvcdynctrl -s 'LED1 Mode' 2   # LED blinking
$ uvcdynctrl -s 'LED1 Mode' 3   # LED auto mode


Your donation will support ongoing availability and give you access to the PDF version of this book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2022 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0