This commit is contained in:
Christophe Maudoux 2018-08-13 23:05:57 +02:00
parent 7f09e1f960
commit bf385a84ce
2 changed files with 3 additions and 3 deletions

View File

@ -171,7 +171,7 @@ sub run {
$self->p->updatePersistentSession( $req,
{ _2fDevices => to_json( \@keep ) } );
$self->userLogger->notice('TOTP registration succeed');
return [ 200, [ 'Content-Type' => 'application/json' ],
return [ 200, [ 'Content-Type' => 'application/json', 'Content-Length' => 12, ],
['{"result":1}'] ];
}
@ -304,7 +304,7 @@ sub run {
$self->p->updatePersistentSession( $req,
{ _2fDevices => to_json( \@keep ) } );
$self->userLogger->notice('TOTP deletion succeed');
return [ 200, [ 'Content-Type' => 'application/json' ],
return [ 200, [ 'Content-Type' => 'application/json', 'Content-Length' => 12, ],
['{"result":1}'] ];
}
}

View File

@ -70,7 +70,7 @@ sub run {
],
[$challenge]
];
return [ 200, [ 'Content-Type' => 'application/json' ], [$challenge] ];
# return twice ??? return [ 200, [ 'Content-Type' => 'application/json' ], [$challenge] ];
}
if ( $action eq 'registration' ) {
my ( $resp, $challenge );