Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wp-digital/inncognito
Login and Registration with user's AWS Cognito account.
https://github.com/wp-digital/inncognito
aws aws-cognito cognito wordpress wordpress-plugin
Last synced: about 2 months ago
JSON representation
Login and Registration with user's AWS Cognito account.
- Host: GitHub
- URL: https://github.com/wp-digital/inncognito
- Owner: wp-digital
- Created: 2022-04-29T20:33:10.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-01-04T10:02:14.000Z (about 2 years ago)
- Last Synced: 2024-10-31T16:50:59.483Z (2 months ago)
- Topics: aws, aws-cognito, cognito, wordpress, wordpress-plugin
- Language: PHP
- Homepage:
- Size: 339 KB
- Stars: 0
- Watchers: 10
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Inncognito
### Description
Login and Registration with user's AWS Cognito account.
### Install
- Preferable way is to use [Composer](https://getcomposer.org/):
````
composer require innocode-digital/wp-inncognito
````By default, it will be installed as [Must Use Plugin](https://codex.wordpress.org/Must_Use_Plugins).
It's possible to control with `extra.installer-paths` in `composer.json`.- Alternate way is to clone this repo to `wp-content/mu-plugins/` or `wp-content/plugins/`:
````
cd wp-content/plugins/
git clone [email protected]:innocode-digital/inncognito.git
cd inncognito/
composer install
````If plugin was installed as regular plugin then activate **AWS Lambda Prerender** from Plugins page
or [WP-CLI](https://make.wordpress.org/cli/handbook/): `wp plugin activate inncognito`.### Configuration
Add the following constants to `wp-config.php`:
````
define( 'INNCOGNITO_DOMAIN', '' ); // Either domain or fully qualified URL (Cognito or custom).
define( 'INNCOGNITO_CLIENT_ID', '' );
define( 'INNCOGNITO_CLIENT_SECRET', '' );
define( 'INNCOGNITO_REGION', '' ); // e.g. eu-west-1
define( 'INNCOGNITO_USER_POOL_ID', '' );
````### Usage
Change callback URL:
```
define( 'INNCOGNITO_REDIRECT_URI', 'https://another-site.com/login/' );
```Use case could be when e.g. you do not want to be limited with callback URL requirement
(it's required to set all callbacks in Cognito settings) but want to use one with custom
redirects handling.---
Change login URL to custom endpoint:
```
define( 'INNCOGNITO_ENDPOINT', 'cognito' ); // default: 'inncognito'
```---
Change session cookie name:
```
define( 'INNCOGNITO_COOKIE', 'cognito' ); // default: 'inncognito'
```Session is used to handle actions and redirects, prevent CSRF attacks.
---
Force users to log in with their AWS Cognito account:
```
define( 'INNCOGNITO_FORCE_COGNITO', true );
```Works for users who were logged in with SSO at least once.
---
Disable registration through AWS Cognito during SSO:
````
define( 'INNCOGNITO_DISALLOW_REGISTRATION', true );
````