u2fKey = $u2fKey; $this->session = $session; } /** * @inheritdoc */ public function getJsLayout() { $this->jsLayout['components']['msp-twofactorauth-auth']['postUrl'] = $this->getUrl('*/*/authpost'); $this->jsLayout['components']['msp-twofactorauth-auth']['successUrl'] = $this->getUrl($this->_urlBuilder->getStartupPageUrl()); $this->jsLayout['components']['msp-twofactorauth-auth']['touchImageUrl'] = $this->getViewFileUrl('MSP_TwoFactorAuth::images/u2f/touch.png'); $this->jsLayout['components']['msp-twofactorauth-auth']['authenticateData'] = $this->u2fKey->getAuthenticateData($this->session->getUser()); return parent::getJsLayout(); } }