<?xml version="1.0" encoding="UTF-8"?>
<authdriver id="authfront.otp" enabled="false" name="authfront.otp" label="CONF_MESSAGE[Authentication One-time-password]" description="CONF_MESSAGE[Use Google Authenticator, Yubikey or standard password to authenticate users.]" mixins="authdriver_commons"  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:../core.ajaxplorer/ajxp_registry.xsd">
    <plugin_info>
        <plugin_author>Janos Milus / Tran Cuong</plugin_author>
        <plugin_version>0.8</plugin_version>
        <plugin_uri>http://pyd.io/plugins/authfront/otp</plugin_uri>
        <core_relation packaged="true" tested_version="follow_core"/>
    </plugin_info>
    <client_settings>
        <resources>
            <i18n namespace="authfront.otp" path="plugins/authfront.otp/i18n"/>
            <js className="OTP_LoginForm" file="plugins/authfront.otp/class.OTP_LoginForm.js" autoload="true"/>
        </resources>
    </client_settings>
    <server_settings>
        <global_param name="ORDER" type="integer" label="CONF_MESSAGE[Order]" description="CONF_MESSAGE[Order this plugin with other auth frontends]" default="13"/>
        <global_param name="PROTOCOL_TYPE" type="select"
                      choices="session_only|CONF_MESSAGE[Sessions Only]"
                      label="CONF_MESSAGE[Protocol Type]" description="CONF_MESSAGE[Enable/disable automatically based on the protocol used]" default="session_only" editable="false"/>
        <global_param  expose="true" name="MODIFY_LOGIN_SCREEN" group="CONF_MESSAGE[General]" type="boolean" label="CONF_MESSAGE[Modify login page]"
                       description="CONF_MESSAGE[Login page will be modified to give user a OTP textbox.]" default="true"/>
        <global_param name="YUBICO_SECRET_KEY" type="string" label="CONF_MESSAGE[Yubico Secret Key]" description="CONF_MESSAGE[Yubico secret key attached to your account]" mandatory="false"/>
        <global_param name="YUBICO_CLIENT_ID" type="string" label="CONF_MESSAGE[Yubico Client ID]" description="CONF_MESSAGE[Yubico client id attached to your account]" mandatory="false"/>
        <param name="yubikey1" type="string" label="CONF_MESSAGE[YubiKey 1]"  description="CONF_MESSAGE[YubiKey 1]" mandatory="false"/>
        <param name="yubikey2" type="string" label="CONF_MESSAGE[YubiKey 2]"  description="CONF_MESSAGE[YubiKey 2]" mandatory="false"/>
        <param name="google" type="string" label="CONF_MESSAGE[Google Authenticator]"  description="CONF_MESSAGE[Google Authenticator Secret]" mandatory="false"/>
        <param name="google_last" type="integer" label="CONF_MESSAGE[Google Authenticator Last]"  description="CONF_MESSAGE[Google Authenticator replay protection, do not edit]" mandatory="false" editable="false"/>
    </server_settings>
    <class_definition filename="plugins/authfront.otp/class.OtpAuthFrontend.php" classname="OtpAuthFrontend"/>
    <registry_contributions>
        <external_file filename="plugins/core.auth/standard_auth_actions.xml" include="actions/*" exclude=""/>
        <client_configs>
            <template element="ajxp_desktop" name="otp_script" position="bottom"><![CDATA[
            <script></script>
            ]]></template>
        </client_configs>
    </registry_contributions>
</authdriver>
