<?php
/**
 * Created by PhpStorm.
 * User: damien
 * Date: 17/03/2018
 * Time: 11:53
 */

namespace Actigraph\ActipageBaseBundle\Services;


class ContentSecurityPolicyNonceService
{
    private $nonce;

    public function getNonce(){
        if ($this->nonce === null) {
            $this->nonce = base64_encode(random_bytes(16));
        }
        return $this->nonce;
    }
}