Your IP : 216.73.216.79


Current Path : /var/www/html/ukas/backend/modules/aidynaweb/components/
Upload File :
Current File : /var/www/html/ukas/backend/modules/aidynaweb/components/DynawebApi.php

<?php
/*
 * All SSO Client controllers must extends with this SSO component
 */
namespace backend\modules\aidynaweb\components;

use Yii;

class DynawebApi {

    public static function hash($message, $key) {
        return base64_encode(hash_hmac('sha256', $message, $key, true));
    }

    public static function getToken($context, $nonce) {
        return self::hash($context . $nonce, Yii::$app->params['fileqna']['SECRET_KEY']);
    }
}