Download the PHP package julabo/keycloak_yourls without Composer

On this page you can find all versions of the php package julabo/keycloak_yourls. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package keycloak_yourls

OIDC Keycloak Plugin for YOURLS

This plugin provides OpenID Connect (OIDC) authentication integration with Keycloak for YOURLS, allowing users to authenticate using their Keycloak credentials instead of traditional YOURLS authentication.

Features

Installation

  1. Extract the plugin files to the user/plugins/keycloak/ directory in your YOURLS installation
  2. Run composer install in the plugin directory to install dependencies
  3. Enable the plugin in your YOURLS admin panel or by adding it to your configuration

Configuration Options

The plugin supports configuration through environment variables (recommended) or direct configuration constants. All settings can be defined in a .env file or YOURLS configuration.

OIDC Provider Settings

Setting Environment Variable Required Description
Base URL OIDC_BASE_URL Yes The base URL of your Keycloak server (e.g., https://auth.example.com)
Realm OIDC_REALM Yes The Keycloak realm name
Client Name OIDC_CLIENT_NAME Yes The client ID configured in Keycloak
Client Secret OIDC_CLIENT_SECRET Yes The client secret from Keycloak
Redirect URL OIDC_REDIRECT_URL Yes The callback URL (typically https://yourdomain.com/admin/)

Rate Limiting Settings

Setting Environment Variable Default Description
Max Attempts OIDC_MAX_AUTH_ATTEMPTS 5 Maximum failed authentication attempts before lockout
Lockout Time OIDC_AUTH_LOCKOUT_TIME 900 Lockout duration in seconds (900 = 15 minutes)
Token Refresh OIDC_TOKEN_REFRESH_THRESHOLD 300 Time in seconds before token expiry to refresh (300 = 5 minutes)

Security Settings

Setting Environment Variable Default Description
Bypass YOURLS Auth OIDC_BYPASS_YOURLS_AUTH true Whether to bypass native YOURLS authentication

Environment Configuration Example

Create or update your .env file with the following settings:

Keycloak Configuration

Client Setup

  1. Create a new client in your Keycloak realm
  2. Set Client ID to match OIDC_CLIENT_NAME
  3. Enable Client Authentication (for confidential clients)
  4. Set Valid Redirect URIs to your OIDC_REDIRECT_URL
  5. Copy the Client Secret to use as OIDC_CLIENT_SECRET
  6. Proof Key for Code Exchange Code Challenge Method set to S256

Required Client Settings

Security Considerations

Rate Limiting

The plugin automatically creates a database table for tracking failed authentication attempts:

Token Security

Database Tables

The plugin creates the following table:

Troubleshooting

Common Issues

  1. "Client not found" error

    • Verify matches the client ID in Keycloak OIDC_CLIENT_NAME
    • Ensure the client is enabled in Keycloak
  2. "Invalid redirect URI" error

    • Check that matches exactly with Keycloak client settings OIDC_REDIRECT_URL
    • Ensure the URL includes the protocol (https://)
  3. Rate limiting not working

    • Verify database permissions allow table creation
    • Check that the rate limit constants are properly defined
  4. Authentication loop
    • Confirm is set to true OIDC_BYPASS_YOURLS_AUTH
    • Verify session handling is working correctly

Debugging

Enable debugging by checking YOURLS error logs and Keycloak server logs. The plugin respects YOURLS debugging settings.

Dependencies

License

This project is licensed under the MIT License - see the LICENSE file for full license text.

Support

For issues and feature requests, please refer to your YOURLS plugin documentation or contact your system administrator.


All versions of keycloak_yourls with dependencies

PHP Build Version
Package Version
Requires php Version >=8.0
stevenmaguire/oauth2-keycloak Version ^6.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package julabo/keycloak_yourls contains the following files

Loading the files please wait ...