Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15480494
D19896.id47557.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D19896.id47557.diff
View Options
diff --git a/src/applications/legalpad/controller/LegalpadDocumentSignController.php b/src/applications/legalpad/controller/LegalpadDocumentSignController.php
--- a/src/applications/legalpad/controller/LegalpadDocumentSignController.php
+++ b/src/applications/legalpad/controller/LegalpadDocumentSignController.php
@@ -151,21 +151,6 @@
$errors = array();
$hisec_token = null;
if ($request->isFormOrHisecPost() && !$has_signed) {
-
- // Require two-factor auth to sign legal documents.
- if ($viewer->isLoggedIn()) {
- $workflow_key = sprintf(
- 'legalpad.sign(%s)',
- $document->getPHID());
-
- $hisec_token = id(new PhabricatorAuthSessionEngine())
- ->setWorkflowKey($workflow_key)
- ->requireHighSecurityToken(
- $viewer,
- $request,
- $document->getURI());
- }
-
list($form_data, $errors, $field_errors) = $this->readSignatureForm(
$document,
$request);
@@ -192,6 +177,20 @@
$signature->setVerified($verified);
if (!$errors) {
+ // Require MFA to sign legal documents.
+ if ($viewer->isLoggedIn()) {
+ $workflow_key = sprintf(
+ 'legalpad.sign(%s)',
+ $document->getPHID());
+
+ $hisec_token = id(new PhabricatorAuthSessionEngine())
+ ->setWorkflowKey($workflow_key)
+ ->requireHighSecurityToken(
+ $viewer,
+ $request,
+ $document->getURI());
+ }
+
$signature->save();
// If the viewer is logged in, signing for themselves, send them to
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Apr 9, 2:28 PM (3 w, 5 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7692622
Default Alt Text
D19896.id47557.diff (1 KB)
Attached To
Mode
D19896: In Legalpad, prompt for MFA at the end of the workflow instead of the beginning
Attached
Detach File
Event Timeline
Log In to Comment