PHPackages                             pbiering/rcguard - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. pbiering/rcguard

ActiveRoundcube-plugin[Mail &amp; Notifications](/categories/mail)

pbiering/rcguard
================

Roundcube plugin that enforces requirement of solving a Captcha during login

1.4.0(2y ago)8325↓64.3%2[3 issues](https://github.com/pbiering/roundcube-rcguard/issues)[1 PRs](https://github.com/pbiering/roundcube-rcguard/pulls)GPL-3.0+PHPPHP &gt;=5.4

Since Oct 7Pushed 2y ago2 watchersCompare

[ Source](https://github.com/pbiering/roundcube-rcguard)[ Packagist](https://packagist.org/packages/pbiering/rcguard)[ Docs](https://github.com/pbiering/roundcube-rcguard)[ RSS](/packages/pbiering-rcguard/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (1)Dependencies (1)Versions (29)Used By (0)

Roundcube webmail plugin "rcguard"
==================================

[](#roundcube-webmail-plugin-rcguard)

Introduction
------------

[](#introduction)

This plugin logs failed login attempts and requires users to go through a CAPTCHA verification process when the number of failed attempts go too high. It provides protection against automated attacks.

Failed attempts are logged by IP and stored in a database table. IPs are also released after a certain expire amount of time.

Since 2024-01-01 the default config is set to always activate CAPTCHA verification by

`$config['failed_attempts'] = 0;`

Sources
-------

[](#sources)

### Repositories

[](#repositories)

- GitHub:

### Registrations

[](#registrations)

- Packagist:

Installation
------------

[](#installation)

### With Composer

[](#with-composer)

Add this plugin `pbiering/rcguard` to the `require` section of your Roundcube `composer.json`, run composer update and enable rcguard in the main Roundcube configuration file.
OR just run:

```
composer require pbiering/rcguard

```

### Manually

[](#manually)

Place the contents of this directory under `plugins/rcguard`.

### Fedora/EL via RPM

[](#fedorael-via-rpm)

until provided by Fedora or EPEL: available via Copr:

```
yum install roundcubemail-plugin-rcguard

```

Activation
----------

[](#activation)

Enable rcguard in the main Roundcube configuration file (e.g. `/etc/roundcubemail/config.inc.php`) by extension of the plugin config array:

`array_push($config['plugins'], 'rcguard');`

Configuration
-------------

[](#configuration)

Copy `config.inc.php.dist` to `config.inc.php` and modify as necessary.

Use the files under `SQL/` to create the database schema required for rcguard. The table should be created in the database used by Roundcube. **NOTE**: If you use the Roundcube `db_prefix` config option, you must rename the table `rcguard` accordingly.

Example for SQLite:

```
cd /usr/share/roundcubemail/plugins/rcguard
cat SQL/sqlite.initial.sql | sqlite3 /var/lib/roundcubemail/db/sqlite.db

```

### Customizing CAPTCHA

[](#customizing-captcha)

**IMPORTANT: This plugin requires CAPTCHA API keys to work properly.**
These can be obtained from:

- Google's reCAPTCHA:
- hCaptcha:
- Friendly Captcha:
- Cloudflare's Turnstile:

You may customize the following in the `config.inc.php` file:

- the API version: `v3`, `v2invisible`, `v2`, `v2hcaptcha` or `v2friendlycaptcha` or `v2cfturnstile`; by `$config['recaptcha_api_version']`

    - also configure per selected service required `$config['recaptcha_api_url']`, `$config['recaptcha_publickey']`, `$config['recaptcha_privatekey']`
- the v2 widget theme: `light` or `dark` (where supported); by `$config\['recaptcha\_theme'\]'
- the v2 widget size: `normal` or `compact` (where supported). by `$config['recaptcha_size']`

For more information about the widget please check:

- [documentation about Google's reCAPTCHA](https://developers.google.com/recaptcha/intro)
- [documentation about hCaptcha](https://docs.hcaptcha.com/).
- [documentation about Friendly Captcha](https://docs.friendlycaptcha.com/)
- [documentation about Cloudflare's Turnstile](https://developers.cloudflare.com/turnstile/)

The plugin configuration file has several other options you may configure, please take at look.

Since May 2018, you can define a proxy (anonymous or authenticated) to request the CAPTCHA widget.

Since April 2022, support for hCaptcha and Friendly Captcha was added

Since March 2023, support for Cloudflare's Turnstile was added

Supported databases
-------------------

[](#supported-databases)

- MySQL
- PostgreSQL
- SQLite

Contact
-------

[](#contact)

The original author of this plugin was [Denny Lin](https://github.com/dennylin93).

[Diana Soares](https://github.com/dsoares) forked it some years ago to 1) use reCAPTCHA v2.0, 2) add the larry skin and 3) because the project issues were taking too long to be answered. Also, the original project was not updated since 2015 and many things have changed in the meantime in Roundcube's API.

[Peter Bieringer](https://github.com/pbiering) forked it 2022 from [Diana Soares](https://github.com/dsoares) to add additional Captcha services.

Because of the former fork went also stale in 2021 ([dsoares#50](https://github.com/dsoares/roundcube-rcguard/issues/50)), [Peter Bieringer](https://github.com/pbiering) will maintain this project now.

Comments and suggestions are welcome via "issues".

License
-------

[](#license)

This plugin is distributed under the GPL-3.0+ license.

This plugin also contains PHP libraries for

- reCAPTCHA
- hCaptcha
- FriendlyCaptcha
- Cloudflare Turnstile

that are distributed under its own licenses. See the library files for the exact details.

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity69

Established project with proven stability

 Bus Factor1

Top contributor holds 60.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~129 days

Recently: every ~335 days

Total

23

Last Release

1070d ago

PHP version history (3 changes)1.0.0PHP &gt;=5.2.1

1.1.0PHP &gt;=5.3.0

1.3.0PHP &gt;=5.4

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/8064668?v=4)[Peter Bieringer](/maintainers/pbiering)[@pbiering](https://github.com/pbiering)

---

Top Contributors

[![dsoares](https://avatars.githubusercontent.com/u/673736?v=4)](https://github.com/dsoares "dsoares (87 commits)")[![pbiering](https://avatars.githubusercontent.com/u/8064668?v=4)](https://github.com/pbiering "pbiering (42 commits)")[![cagdasbas](https://avatars.githubusercontent.com/u/7910267?v=4)](https://github.com/cagdasbas "cagdasbas (3 commits)")[![Maxqia](https://avatars.githubusercontent.com/u/10419267?v=4)](https://github.com/Maxqia "Maxqia (2 commits)")[![Mindless999](https://avatars.githubusercontent.com/u/20699783?v=4)](https://github.com/Mindless999 "Mindless999 (2 commits)")[![tokred](https://avatars.githubusercontent.com/u/12331973?v=4)](https://github.com/tokred "tokred (2 commits)")[![valarauco](https://avatars.githubusercontent.com/u/434898?v=4)](https://github.com/valarauco "valarauco (1 commits)")[![cslevi81](https://avatars.githubusercontent.com/u/18506732?v=4)](https://github.com/cslevi81 "cslevi81 (1 commits)")[![sjinks](https://avatars.githubusercontent.com/u/7810770?v=4)](https://github.com/sjinks "sjinks (1 commits)")[![evandrofisico](https://avatars.githubusercontent.com/u/290162?v=4)](https://github.com/evandrofisico "evandrofisico (1 commits)")[![edtsz](https://avatars.githubusercontent.com/u/3809579?v=4)](https://github.com/edtsz "edtsz (1 commits)")

---

Tags

captchapluginroundcuberoundcube-pluginroundcube-webmailroundcube-webmail-pluginsecuritymailroundcubecaptcha

### Embed Badge

![Health badge](/badges/pbiering-rcguard/health.svg)

```
[![Health](https://phpackages.com/badges/pbiering-rcguard/health.svg)](https://phpackages.com/packages/pbiering-rcguard)
```

###  Alternatives

[zbateson/mail-mime-parser

MIME email message parser

54753.3M91](/packages/zbateson-mail-mime-parser)[dsoares/rcguard

Roundcube plugin that enforces reCAPTCHA for users that have too many failed logins

254.0k](/packages/dsoares-rcguard)[toteph42/identity_switch

This plugin allows users to switch between different identities (and check for new mails) in a single Roundcube session.

221.5k](/packages/toteph42-identity-switch)[zbateson/stream-decorators

PHP psr7 stream decorators for mime message part streams

4752.6M9](/packages/zbateson-stream-decorators)[opcodesio/mail-parser

Parse emails without the mailparse extension

228.8M11](/packages/opcodesio-mail-parser)[kitist/html5_notifier

Desktop Notifications for Roundcube

7911.8k](/packages/kitist-html5-notifier)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
