Home / Integration plugins / PrivacyIDEA SMS OTP Integration

+

Send SMS OTP codes from privacyIDEA

When a user signs in with a privacyIDEA SMS token, the one-time code is sent by SMS through SMSEagle, your own hardware SMS gateway. The request stays in your local network, with no cloud SMS provider.

OTP codes never touch a third party

PrivacyIDEA already keeps authentication data on-premise – SMSEagle extends that principle to delivery. Codes are sent from your own device over the cellular network, with no cloud SMS provider in between.

Works in isolated and air-gapped networks

PrivacyIDEA is often deployed in environments with strict network segmentation. SMSEagle sends messages over its own cellular connection, so OTP delivery works even when the PrivacyIDEA server has no outbound internet access.

Predictable cost, no vendor dependency

SMSEagle sends SMS through a standard SIM card at local carrier rates, with no per-message fees and no external SMS gateway contract to manage alongside privacyIDEA.

How it works

1

Login attempt

A user authenticates against a PrivacyIDEA-protected service and passes the first factor.

2

OTP request

privacyIDEA’s HttpSMSProvider sends the one-time code to the SMSEagle device’s APIv2 over the local network.

3

Code delivery

SMSEagle delivers the code over its own cellular connection, not through a third-party service, as an SMS to the user’s own phone.

Set up in about 10 minutes

Create an SMS gateway definition in privacyIDEA with the SMSEagle address and API token, and codes are sent by SMS.

SMSEagle sends privacyIDEA one-time codes by SMS from your own device, with no cloud SMS provider.

Works on any phone

An SMS code needs no app: people receive it on any mobile phone.

Every code sent is recorded

SMSEagle records every code it sends, together with its status, so you can check whether it was received.

Logins work even if one device fails

Two SMSEagle devices can work as an HA cluster: if one fails, the other takes over sending codes.

SMSEagle configuration

Before using the API, you’ll need to enable API access on your SMSEagle device by following these steps:

    1. Navigate to the Web-GUI and select the System > Users menu.
    2. Create a new user in SMSEagle, user access level: “User”.
    3. Go to Settings > Global settings > API and open the API v2 page.
    4. Click Create API key, fill in Key name and select that user as Owner.
    5. Set up the appropriate permissions in the Permissions section, then click Create key – the access token is shown only once, right after saving:
      • For purpose of this example configuration, add access permissions in section Messages for: Send SMS.

PrivacyIDEA configuration

Below is the example configuration for the Send SMS method from our APIv2, however, you can also use different methods (e.g. mms_post), more information about our APIv2 can be found here: https://www.smseagle.eu/docs/apiv2/

Go to the Config tab, then System and SMS Gateways.

Here choose Create New SMS Gateway Definition and as Providermodule select HttpSMSProvider.

In the HTTP_METHOD field, choose the POST value.

In the RETURN_FAIL and RETURN_SUCCESS enter the values REJECTED and queued.

As for URL, enter your SMSEagle Gateway address with correct APIv2 endpoint.

In the SEND_DATA_AS_JSON field choose yes.

Now, in Options section add a text and to parameters.
As for the to parameter, set this value: [“{phone}”].
In the text parameter you can  enter your personalized sentence,
(for example: “Your OTP code is: {otp}”).
However, it has to be contained inside double-quotes and must include {otp} (which is the placeholder for the one-time password that will be sent).

In Headers section add an access-token parameter and as its value enter the access token of a user from your SMSEagle Gateway.

Save the Gateway Definition, go to Config > Tokens > SMS and choose your saved SMS Gateway configuration.

Explore SMSEagle Demo device

SMSEagle is a hardware & software solution that guarantees a swift delivery of your messages to designated recipients, whether it’s for notifications, alerts, or important updates.

After registering to a demo you get a remote access to our physical device NXS-9750.

  • 14-days free trial
  • Access to over 20 functionalities

What is hardware
SMS Gateway?

Learn more about
SMSEagle features