📋 ClearClipboard

Periodically clear the clipboard, e.g. to hide sensitive information

1 Introduction

ClearClipboard is a simple tool that will periodically clear your clipboard. This is useful, for example, to hide sensitive information, such as passwords. The clear timeout can be configured freely and defaults to 30 seconds. Also, the clipboard will not simply be cleared at a fixed interval. Instead, the clear timer will be reset every time that new content is copied to the clipboard. This ensures that only "stale" content will be cleared; recently copied content will never be cleared away.

Note: The ClearClipboard program runs "hidden" in the background. However, there will be an icon in the notification area, which can be used to control or terminate ClearClipboard. Only one instance of ClearClipboard can be running at a time.

2 System requirements

ClearClipboard runs on Windows Vista or newer. The "x64" version requires a 64-Bit version of Windows Vista or newer.

Windows XP is not supported, i.a., due to the lack of the AddClipboardFormatListener system function!

2.1 Windows 10 Warning

Windows 10 contains some "problematic" features that can put a risk on sensitive information copied to the clipboard:

We highly recommend to disable both of these features in order to keep your data safe and allow ClearClipboard to function as expected. To the best of our knowledge, the most reliable way to achieve this is to completely disabled the "Clipboard History" (cbdhsvc) system service. ClearClipboard will now detect whether the "problematic" service is running on your system, and if so, offer to disable that service. Note that a reboot will be required in order to make the changes take effect.

2.1.1 Registry Hacks

Optionally, you can disable the "Clipboard History" service with the following .reg file:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\cbdhsvc]
"Start"=dword:00000004
[HKEY_CURRENT_USER\Software\Microsoft\Clipboard]
"EnableClipboardHistory"=dword:00000000

Use this .reg file, if you ever whish to re-enable the "Clipboard History" service:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\cbdhsvc]
"Start"=dword:00000003
[HKEY_CURRENT_USER\Software\Microsoft\Clipboard]
"EnableClipboardHistory"=dword:00000001

As always, a reboot will be required in order to make the above registry "hacks" take effect!

3 Command-line Options

The ClearClipboard program supports the following mutually exclusive command-line options:

In addition, one or more of the following options may be appended to the command-line:

4 Configuration File

The behavior of the ClearClipboard program can be adjusted via a configuration file, in the INI format.

The configuration file must be located in the same directory as the ClearClipboard executable. Also, it must have the same file name as the ClearClipboard executable, except that the file extension is replaced by .ini. The default configuration file name therefore is ClearClipboard.ini. All parameters need to be located in the [ClearClipboard] section.

The following configuration parameters are supported:

4.1 Example Configuration

An example configuration file:

[ClearClipboard]
Timeout=90000
TextOnly=1
Sound=2
Hotkey=0x342
Halted=1

5 Updates & Source Code

Please check the official web-site at http://muldersoft.com/ or http://muldersoft.sourceforge.net/ for updates!

The source code of ClearClipboard is available from our public Git repository, mirrored at:

6 Version History

Version 1.07 [2019-06-15]

Version 1.06 [2019-06-05]

Version 1.05 [2019-06-02]

Version 1.04 [2019-06-01]

Version 1.03 [2019-05-31]

Version 1.02 [2019-05-26]

Version 1.01 [2019-05-25]

7 License

Copyright(â’¸) 2019 LoRd_MuldeR , released under the MIT License.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software
and associated documentation files (the "Software"), 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 "AS IS", 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.

https://opensource.org/licenses/MIT

 
e.o.f.