From: <de...@de...> - 2014-09-11 00:25:53
|
Author: PeterThoeny Date: 2014-09-10 19:20:03 -0500 (Wed, 10 Sep 2014) New Revision: 28050 Trac url: http://develop.twiki.org/trac/changeset/28050 Added: twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemaillogin.tmpl twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemailmessage.tmpl Log: Item7540: Initial version of SmsTwoStepAuthContrib for two-step authentication using SMS - add templates for e-mail auth, separate from SMS auth Added: twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemaillogin.tmpl =================================================================== --- twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemaillogin.tmpl (rev 0) +++ twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemaillogin.tmpl 2014-09-11 00:20:03 UTC (rev 28050) @@ -0,0 +1,62 @@ +%{ Login template of SmsTwoStepAuthContrib }% +%TMPL:INCLUDE{"twiki"}% + +%TMPL:DEF{"webaction"}%%MAKETEXT{"TWiki Two Factor Authentication"}%%TMPL:END% +%TMPL:DEF{"titleaction"}%%MAKETEXT{"(E-mail login)"}% %TMPL:END% +%TMPL:DEF{"LOG_IN_BANNER"}%%TMPL:END% +%TMPL:DEF{"LOGGED_IN_BANNER"}%%TMPL:END% + +%TMPL:DEF{"pagetitle"}%%TMPL:END% + +%TMPL:DEF{"titleaction"}%%MAKETEXT{"([_1] login)" args="<nop>%WIKITOOLNAME%"}%%TMPL:END% + +%TMPL:DEF{"title"}%---++ %MAKETEXT{"Please enter the access code received by e-mail"}% +%TMPL:END% + +%TMPL:DEF{"titlestep"}%<div class="twikiFormStep"> +%TMPL:P{"title"}% +%TMPL:P{"notestep"}% +%TMPL:P{"errorstep"}%</div><!-- /twikiFormStep-->%TMPL:END% + +%TMPL:DEF{"notestep"}%<div style="display:%IF{'defined ERROR or defined NOTE or defined BANNER' then='block' else='none'}%;"> +%IF{"defined NOTE AND $NOTE != ''" then='---+++ %NOTE%'}%</div>%TMPL:END% + +%TMPL:DEF{"errorstep"}%%IF{"defined BANNER AND $BANNER != ''" then='<div class="twikiNotification twikiAlert twikiUnvisited patternLoginNotification">%BANNER%%IF{"defined ERROR AND $ERROR != ''" then='<!--%TMPL:P{"error"}%-->'}%</div>'}%%TMPL:END% + +%TMPL:DEF{"error"}%%MAKETEXT{"Error: [_1]" args="%ERROR%"}%%TMPL:END% + +%TMPL:DEF{"formstart"}%<form action='%SCRIPTURLPATH{"login"}%/%WEB%/%TOPIC%' name='loginform' method='post'>%TMPL:END% + +%TMPL:DEF{"formend"}%<literal> <input type='hidden' name='username' value='%LOGINNAME%' /> %QUERYPARAMS{encoding="entity" format="<input type='hidden' name='$name' value='$value' />"}% </literal><input type="hidden" name="origurl" value="%ORIGURL%" /></form>%TMPL:END% + +%TMPL:DEF{"accesscodefield"}%<input tabindex='1' type='text' class='twikiInputField twikiFocus' size='40' name='accesscode' value='' />%TMPL:END% + +%TMPL:DEF{"accesscodestep"}%<div class="twikiFormStep"> +---+++ %MAKETEXT{"Access code for <nop>[_1]" args="%LOGINNAME%"}% + +%TMPL:P{"accesscodefield"}% %TMPL:P{"accesscodefieldhelp"}% + +</div><!-- /twikiFormStep-->%TMPL:END% + +%TMPL:DEF{"accesscodenote"}%This <nop>%WIKITOOLNAME% requires two-step authentication. This is step two. Please check your e-mail - you will get a one-time-use access code. Enter the access code to log in. %TMPL:END% + +%TMPL:DEF{"accesscodefieldhelp"}% <div class="twikiHelp">%TMPL:P{"accesscodenote"}%</div> %TMPL:END% + +%TMPL:DEF{"submitstep"}%<div class="twikiFormStep">%TMPL:P{"submit"}%</div><!-- /twikiFormStep-->%TMPL:END% + +%TMPL:DEF{"submit"}%<input tabindex='4' type='submit' class='twikiSubmit' value='%MAKETEXT{"Logon"}%' />%TMPL:END% + +%{ please keep the spaces between the div and the TMPL seealsonote, it allows TWiki to process the emailaddress }% +%TMPL:DEF{"seealsostep"}%<div class="twikiFormStep twikiGrayText twikiLast"> %TMPL:P{"seealsonote"}% </div><!-- /twikiFormStep-->%TMPL:END% + +%TMPL:DEF{"seealsonote"}% %MAKETEXT{"If you have any questions, please contact [_1]" args="%IF{"defined WIKIWEBMASTER AND $WIKIWEBMASTER != ''" then="%WIKIWEBMASTER%" else="your TWiki administrator"}%"}% %TMPL:END% + +%TMPL:DEF{"form"}%<div id="twikiLogin"> +<div class="twikiFormSteps">%TMPL:P{"formstart"}%%TMPL:P{"titlestep"}% +%TMPL:P{"accesscodestep"}%%TMPL:P{"submitstep"}% +%TMPL:P{"formend"}% +%TMPL:P{"seealsostep"}% +</div><!-- /twikiFormSteps--> +</div><!-- /twikiLogin-->%TMPL:END% + +%TMPL:DEF{"content"}%%TMPL:P{"form"}%%TMPL:END% Added: twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemailmessage.tmpl =================================================================== --- twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemailmessage.tmpl (rev 0) +++ twiki/trunk/SmsTwoStepAuthContrib/templates/smstwostepemailmessage.tmpl 2014-09-11 00:20:03 UTC (rev 28050) @@ -0,0 +1,7 @@ +%{ E-mail template of SmsTwoStepAuthContrib }%From: %WIKIWEBMASTERNAME% <%WIKIWEBMASTER%> +To: %EMAILADDRESS% +Subject: %WIKITOOLNAME% Access Code for Two-step Authentication + +Your access code: %ACCESSCODE% + +Questions? Contact %WIKIWEBMASTER% |