Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Temporary / additional fix for deactivation of TOTP #1247

Merged
merged 9 commits into from
Aug 18, 2022
Merged

Temporary / additional fix for deactivation of TOTP #1247

merged 9 commits into from
Aug 18, 2022

Conversation

i-oden
Copy link
Member

@i-oden i-oden commented Aug 17, 2022

Description

The idea from the beginning was that it should be possible to activate HOTP if you lose access to the authentication app at some point. This doesn't work since it attempts to get the authentication code while reauthenticating.

This PR adds an endpoint for Super Admins to be able to deactivate a users TOTP and thereby allowing them to either use HOTP or reset a new TOTP on their new device. This is a first step before we fix another, secure enough solution.

  • Summary of the changes and the related issue
  • Relevant motivation and context
  • Any dependencies that are required for this change

Fixes DDS-1319

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

Please delete options that are not relevant.

  • Any dependent changes have been merged and published in downstream modules
  • Rebase/merge the branch which this PR is made to
  • Changes to the database schema: A new migration is included in the PR
  • Product Owner / Scrum Master: This PR is made to the master branch and I have updated the version
  • I am bumping the major version (e.g. 1.x.x to 2.x.x) and I have made the corresponding changes to the CLI version

Formatting and documentation

  • I have added a row in the changelog
  • The code follows the style guidelines of this project: Black / Prettier formatting
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

Tests

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@i-oden i-oden marked this pull request as ready for review August 17, 2022 13:38
@i-oden i-oden requested a review from valyo August 17, 2022 13:38
@i-oden i-oden self-assigned this Aug 17, 2022
@i-oden i-oden added the bug Something isn't working label Aug 17, 2022
@codecov
Copy link

codecov bot commented Aug 17, 2022

Codecov Report

Merging #1247 (005c82c) into dev (efa0cba) will increase coverage by 0.05%.
The diff coverage is 100.00%.

❗ Current head 005c82c differs from pull request most recent head 81381fb. Consider uploading reports for the commit 81381fb to get more accurate results

@@            Coverage Diff             @@
##              dev    #1247      +/-   ##
==========================================
+ Coverage   87.41%   87.47%   +0.05%     
==========================================
  Files          29       29              
  Lines        3782     3799      +17     
==========================================
+ Hits         3306     3323      +17     
  Misses        476      476              
Impacted Files Coverage Δ
dds_web/api/__init__.py 100.00% <100.00%> (ø)
dds_web/api/superadmin_only.py 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@i-oden i-oden merged commit c005f18 into dev Aug 18, 2022
@i-oden i-oden deleted the twofactor branch August 18, 2022 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant