Basic Authentication

For enhanced chargestation connection security

Introduction

Using basic authentication, you can now enable a secure communication channel between eDRV cloud and your chargestation.

📘

On Basic Auth - from the OCPP 1.6J specification

  • The security profile shall be configured before OCPP communication is enabled. Both Charge Point and Central System shall only use one security profile i.e basic auth (Unsecured Transport with Basic Authentication)
  • Username should be equal to the Charge Point identity, which is the identifying string of the Charge Point as it uses it in the OCPP-J connection URL.
  • The password shall be stored in the AuthorizationKey Configuration Key.

Enable Security

via Admin Dashboard

Go to chargestation section > click on edit chargestion > change security setting to basic auth and update.

26002600

Update Security Setting to Basic Auth

via API

Use chargestation patch api to enable the security settings

const request = require('request');

const options = {
  method: 'PATCH',
  url: 'https://api.edrv.io/v1.1/chargestations/5fca57b3fbfcc320b3b03f22',
  headers: {
    Accept: 'application/json',
    'Content-Type': 'application/json',
    Authorization: 'Bearer eDRV_TOKEN'
  },
  body: {
     "security": {
          "type": "basic_auth"
     }
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
  const chargestationid  = body.result._id;
  
});

Get Security Credentials

via Admin Dashboard

Go to chargestation section > click on info icon

17981798

via API

Use GET Charge station by ID API to get the security setting for a charge station.

Reset Password

via Admin Dashboard

Go to chargestation section > click on info icon > Click on the Reset Password link in the password column.

17981798

Reset password

via API

Use charge station reset password api

const request = require('request');

const options = {
  method: 'PATCH',
  url: 'https://api.edrv.io/v1.1/chargestations/5fca57b3fbfcc320b3b03f22/reset_password',
  headers: {
    Accept: 'application/json',
    'Content-Type': 'application/json',
    Authorization: 'Bearer eDRV_TOKEN'
  },
  json: true
};

request(options, function (error, response, body) {
  if (error) throw new Error(error);

  console.log(body);
  const chargestationid  = body.result._id;
  
});