PHPackages                             jeanmarcos/module-customer-bypass - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. jeanmarcos/module-customer-bypass

ActiveMagento2-module[Authentication &amp; Authorization](/categories/authentication)

jeanmarcos/module-customer-bypass
=================================

Magento 2 development module that bypasses storefront customer authentication so any password is accepted for any existing customer. For local development only — guarded against production mode.

1.1.0(2mo ago)001MITPHPPHP ~8.1.0||~8.2.0||~8.3.0

Since Apr 27Pushed 2mo agoCompare

[ Source](https://github.com/jeanmarcos-dev/module-customer-bypass)[ Packagist](https://packagist.org/packages/jeanmarcos/module-customer-bypass)[ RSS](/packages/jeanmarcos-module-customer-bypass/feed)WikiDiscussions main Synced 3w ago

READMEChangelogDependencies (4)Versions (3)Used By (1)

> 📦 **`jeanmarcos/module-customer-bypass`** — published to [Packagist](https://packagist.org/packages/jeanmarcos/module-customer-bypass).
>
> 🏠 **Source repository** for issues, PRs and releases: **[jeanmarcos-dev/magento-local-development](https://github.com/jeanmarcos-dev/magento-local-development)**. The standalone [`jeanmarcos-dev/module-customer-bypass`](https://github.com/jeanmarcos-dev/module-customer-bypass) repo is a **read-only mirror** auto-generated by CI on every release — direct commits to it are overwritten.

Development\_CustomerBypass
===========================

[](#development_customerbypass)

[![Packagist](https://camo.githubusercontent.com/393466ff2a3700aefbbaba17be7155e40cbc83b9f41321e71afc828ae1dc93c3/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a65616e6d6172636f732f6d6f64756c652d637573746f6d65722d6279706173732e737667)](https://packagist.org/packages/jeanmarcos/module-customer-bypass)

> ⚠️ **FOR LOCAL DEVELOPMENT ONLY — NEVER ENABLE IN PRODUCTION**

Bypasses Magento 2 customer authentication. Any password is accepted for any existing customer account on storefront login.

---

What it does
------------

[](#what-it-does)

- **`BypassCustomerAuthentication`** (plugin `around` on `Magento\Customer\Model\AccountManagement::authenticate`) — resolves the customer via `CustomerRepositoryInterface::get($username)` and returns it, ignoring the password.

No new users are created; only existing customers can be impersonated.

---

Safety model
------------

[](#safety-model)

Guarded by Magento's application mode:

Mode`Allow in Production` flagBehavior`developer` / `default`any**active** — password ignored`production``No` (default)**inactive** — normal authentication`production``Yes`**active** — explicit overrideImplementation: [`Development_Core`](https://packagist.org/packages/jeanmarcos/module-core-local-development) (`Development\Core\Model\ProductionGuard::isEnabled()`), wired via a `virtualType` in `etc/di.xml` bound to the config path `development/customer_bypass/allow_in_production`. When disabled, the plugin delegates to `$proceed($username, $password)` and Magento authenticates normally.

---

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

[](#configuration)

Panel path: **Stores → Configuration → ⚠ Development Modules → Customer Bypass → General → Allow in Production**

- Default: `No`.
- Changing the flag requires `bin/magento cache:clean config`.

---

Install
-------

[](#install)

```
composer require --dev jeanmarcos/module-customer-bypass
bin/magento module:enable Development_CustomerBypass
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento cache:flush
```

Kill switch
-----------

[](#kill-switch)

```
bin/magento module:disable Development_CustomerBypass
bin/magento setup:upgrade
bin/magento cache:flush
```

For permanent removal:

```
composer remove jeanmarcos/module-customer-bypass
```

---

Security risks
--------------

[](#security-risks)

- Anyone who knows a customer's email/username can log in as them without the password.
- Exposes full order history, addresses, saved payment methods (if stored), and wishlists.
- No audit trail: bypassed logins look identical to legitimate ones in the session.

---

File structure
--------------

[](#file-structure)

```
CustomerBypass/
├── Plugin/
│   └── BypassCustomerAuthentication.php  # password bypass around plugin
├── etc/
│   ├── acl.xml
│   ├── adminhtml/
│   │   └── system.xml
│   ├── config.xml
│   ├── di.xml                            # plugin wiring + ProductionGuard virtualType
│   └── module.xml                        # depends on Development_Core
├── composer.json
├── registration.php
└── README.md

```

The production-guard helper lives in the shared core package [`jeanmarcos/module-core-local-development`](https://packagist.org/packages/jeanmarcos/module-core-local-development).

---

Troubleshooting
---------------

[](#troubleshooting)

- **Toggle doesn't take effect:** `bin/magento cache:clean config`.
- **"Invalid login or password" still appears:** the plugin only overrides `AccountManagement::authenticate`; some integrations (OAuth, external SSO) use different entry points and are unaffected.

---

Compatibility
-------------

[](#compatibility)

- Magento 2.4.x
- PHP 8.1+
- Depends on `jeanmarcos/module-core-local-development` (installed automatically by Composer).

---

License
-------

[](#license)

MIT

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance83

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

88d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/26399111?v=4)[Jeanmarcos](/maintainers/jeanmarcos-dev)[@jeanmarcos-dev](https://github.com/jeanmarcos-dev)

---

Top Contributors

[![jeanmarcos-dev](https://avatars.githubusercontent.com/u/26399111?v=4)](https://github.com/jeanmarcos-dev "jeanmarcos-dev (2 commits)")

---

Tags

authmagentoimpersonationdevelopmentmagento2magento 2customerdev-toolsbypass

### Embed Badge

![Health badge](/badges/jeanmarcos-module-customer-bypass/health.svg)

```
[![Health](https://phpackages.com/badges/jeanmarcos-module-customer-bypass/health.svg)](https://phpackages.com/packages/jeanmarcos-module-customer-bypass)
```

###  Alternatives

[mollie/magento2

Mollie Payment Module for Magento 2

1131.9M16](/packages/mollie-magento2)[loki/magento2-components

Core module for defining Alpine.js components with advanced AJAX features

1011.8k26](/packages/loki-magento2-components)[run-as-root/magento2-prometheus-exporter

Magento2 Prometheus Exporter

68357.9k](/packages/run-as-root-magento2-prometheus-exporter)

PHPackages © 2026

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