IBM Support

SMTP Open Authentication

News


Abstract

This document describes the OAuth 2.0 authentication support for SMTP (Simple Mail Transfer Protocol) in IBM Navigator for i. The feature enables secure email transmission through modern mail providers such as Google Workspace (Gmail) and Microsoft 365 by implementing industry-standard OAuth 2.0 authentication instead of traditional username/password credentials.

OAuth 2.0 provides enhanced security through token-based authentication, eliminating the need to store or transmit user passwords. This implementation allows IBM i systems to authenticate with external mail providers using service accounts and application credentials, meeting modern security requirements and compliance standards.

Content

Overview

This support is new in 2026.  Check the PTFs page for required server side PTFs.

This page is for using IBM Navigator in the OAuth configuration.  This page will give you more information on the overall process:  IBM i Simple Mail Transfer Protocol (SMTP) support for OAuth 2.0

The SMTP OAuth 2.0 feature provides:

  • Secure Authentication: Token-based authentication using OAuth 2.0 protocol
  • Provider Support: Compatible with Google Workspace (Gmail) and Microsoft 365
  • Easy Configuration: Streamlined setup through IBM Navigator for i interface
  • Credential Management: Secure storage of OAuth credentials using IBM i master encryption key
  • Command-Line Support: Extended CHGSMTPA command for OAuth configuration

 

You are in: IBM i Technology Updates  > Navigator for i > Documentation on Functional Areas > Network > SMTP Open Authentication

 

 
Open Authentication - Phase 1
 

Provider Setup

Users must complete the provider-specific setup (Google Cloud Portal or Office 365 Portal) to obtain the necessary credentials before proceeding with IBM Navigator for i configuration.

Navigator Configuration

IBM Navigator for i provides an intuitive interface for OAuth configuration:

  1. Navigate to Network > TCP/IP Servers > SMTP > Properties
  2. Select the OAuth tab
  3. Upload credentials file or specify IFS path
  4. Enable OAuth authentication

The Navigator interface handles the execution of the CHGSMTPA command with appropriate parameters.

CHGSMTPA Command Extension

The existing CHGSMTPA command has been extended to support OAuth configuration through the OAUTH parameter.

Command Syntax

CHGSMTPA OAUTH(Credentials_path Action)

OAUTH Parameter Structure

The OAUTH parameter is a compound parameter consisting of two elements that configure OAuth authentication for the SMTP client when sending outbound mail to a mail provider.

Element 1: Credentials File Path

Values: IFS path, *SAME, *NONE
Default: *SAME

Description:

  • Specifies the path to the JSON credentials file obtained from the mail provider's portal
  • The file contains provider-specific OAuth 2.0 authentication information in JSON format
  • Used to import credentials into the SMTP client

Value Details:

  • IFS path (e.g., /tmp/google.json or /tmp/office365.json):
    • Imports OAuth credentials from the specified file
    • Stores credentials internally for use by the SMTP client
    • Replaces any existing OAuth credentials
  • *SAME:
    • No change is made to the current OAuth credentials configuration
    • If no OAuth credentials are configured, no configuration is created
  • *NONE:
    • Indicates that no credentials file is being supplied
    • Used when disabling or deleting OAuth
    • Does not, by itself, delete stored credentials

Element 2: Action

Values: *SAME, *ENABLE, *DELETE
Default: *SAME

Description:
Controls how OAuth authentication is handled by the SMTP client.

Value Details:

  • *ENABLE:
    • Enables OAuth authentication for the SMTP client
    • If OAuth credentials are already stored, they are reused
    • If no credentials are stored, the command fails
  • *DELETE:
    • Removes all stored OAuth configuration data for the SMTP client
    • Deletes credentials and associated settings
    • This operation is irreversible
  • *SAME:
    • No change is made to the current OAuth usage state

Usage Notes

  1. Credential Import: OAuth credentials are imported once and stored internally; the credentials file path is not required for subsequent enable operations
  2. Credential Persistence: Disabling OAuth does not remove stored credentials
  3. Credential Deletion: Stored credentials are removed only when Action(*DELETE) is specified
  4. Validation: Invalid combinations of credentials path and action values are rejected with an error to prevent ambiguous or accidental configuration changes

Valid OAUTH Parameter Combinations

Only the combinations listed below are valid. All other combinations are rejected with an error.

Credentials_path

Action

Result

file path

*ENABLE

Import credentials and enable OAuth

*NONE

*DELETE

OAuth configuration deleted

*SAME

*SAME

No change



 

 

 

 

 

 

Command Examples

Example 1: Configure OAuth Credentials and Enable Authentication
Imports the credentials file and enables OAuth authentication for the SMTP client in a single step.
CHGSMTPA OAUTH('/tmp/google.json' *ENABLE)
Note: This is the only way to enable OAuth.

Example 2: Delete All OAuth Credentials and Configuration
Explicitly removes all stored OAuth credentials and configuration for the SMTP client.
CHGSMTPA OAUTH(*NONE *DELETE)
WARNING: This operation is irreversible.

Example 3: Preserve Current OAuth Configuration
Makes no changes to OAuth configuration, credentials, or usage.
CHGSMTPA OAUTH(*SAME *SAME)

Security Considerations

Master Encryption Key Requirement

OAuth credentials are encrypted using IBM i master encryption key 1. If master key 1 is not set, users will be prompted to load and set it before configuring OAuth.

Authority Requirements

Users must have *IOSYSCFG special authority to configure OAuth settings for SMTP.

Credential Storage

  • Credentials are stored securely using IBM i encryption
  • Credentials are not stored in plain text
  • Credentials persist across system restarts
  • Credentials can only be deleted using the *DELETE action

User Prototype Results / Scenarios

The OAuth configuration workflow in IBM Navigator for i follows these scenarios:

  1. Initial Setup: User with *IOSYSCFG authority accesses SMTP properties and navigates to OAuth tab
  2. Master Key Check: System verifies master key 1 is set; prompts user if not configured
  3. Credentials Upload: User uploads JSON credentials file from local system or specifies IFS path
  4. OAuth Enable: User enables OAuth authentication
  5. Validation: System validates credentials and configuration
  6. Activation: OAuth authentication is activated for SMTP client

GUI Design

IBM Navigator for i provides functionality for SMTP properties under Network > TCP/IP Servers > SMTP > Configure OAUTH

This is only available when user has *IOSYSCFG special authority.

Figure 1: Enabling OAUTH when user has *IOSYSCFG special authority

 

 

  • Navigator will require master key 1.  If not already set, users will be prompted.
  • When setting the Master Key is required, the Load and Set button will show enabled.
  • When the Master Key is already set, the Load and Set button will show disabled.

 

Figure 2: Credential file path parameter options

Credential file parameter options

 

Figure 3: Click on Browse button prompted to File browser dialog to select path of JSON file from IFS (or) to upload from user local system

Browse

 

Figure 4: Upload dialog when clicking on Upload to button

 

 

Figure 5: The selected files are listed after uploading from the user local system

 

 

Figure 6: Select credentials path from IFS (or) upload from the user local system

Upload to /tmp

 

Figure 7: Action Provider field options

Open Authentication Setup - Action Provider field option

 

[{"Type":"MASTER","Line of Business":{"code":"LOB68","label":"Power HW"},"Business Unit":{"code":"BU070","label":"IBM Infrastructure"},"Product":{"code":"SWG60","label":"IBM i"},"ARM Category":[{"code":"a8m0z0000000CH1AAM","label":"IBM Navigator for i"}],"ARM Case Number":"","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"7.4.0;7.5.0;7.6.0"}]

Document Information

Modified date:
15 June 2026

UID

ibm17273833