Skip to main content

Basic Authentication with Escape

Description

The 'Basic' authentication preset is designed for straightforward authentication scenarios:

  • Credentials Encoding: User's credentials (username and password) are encoded in base64.
  • Header Attachment: The encoded credentials are attached to the request headers.
  • Authorization Header: The client sends these credentials in the Authorization header of the HTTP request.

This method provides a simple and direct way to authenticate users, without requiring additional server requests for user creation or authentication. It is best suited for scenarios where simplicity and ease of implementation are prioritized.

Note: While this method is straightforward, it's less secure compared to more advanced authentication methods.

Examples

presets:
- type: basic
users:
- username: user1
password: pass1
- username: user2
password: pass2

Extensive Configuration

PropertyTypeRequiredDescriptionReference
typeConst[basic]True
usersBasicUserPresetTrueA list of users with basic credentials to createBasicUserPreset

Objects

BasicUserPreset

PropertyTypeRequiredDescriptionReference
usernamestringTrueThe Basic username of the user.
headersDict[string, string]FalseOptional headers injected during the authentication process and in authentified requests.
cookiesDict[string, string]FalseOptional cookies injected during the authentication process and in authentified requests.
passwordstringTrueThe Basic password of the user.