Problem/Motivation

It took a bit of digging to follow #3374260: Allow TFA authentication through REST routes and #3378072: Decorate the user.auth service to figure out how to instruct users to use TFA and REST.

Steps to reproduce

Try as a new dev never having used before

Proposed resolution

Make it easier by documenting on the configuration page if REST is enabled.

Maybe in the README too? Though that duplicates homepage at the moment and maybe its too edge case for homepage?

Remaining tasks

MR

User interface changes

Configuration page has helptext if REST is enabled.

API changes

N/A

Data model changes

N/A

Issue fork tfa-3521300

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

scott_euser created an issue. See original summary.

scott_euser’s picture

Assigned: scott_euser » Unassigned
Status: Active » Needs review

Small change, but will at least be helpful for future me and perhaps other devs

phpstan issue unrelated and occurs on 2.x

cmlara’s picture

Component: Code » Documentation
Status: Needs review » Needs work

For the 2.x we are embracing using GitLab Pages for the documentation/manual. This is rendered by mkdocs from the markdown files in the docs folder and published on each 2.x pipeline execution. It is also currently included in each download for offline viewing.

We likely should place this somewhere in the docs (there may be no great location for it at the moment as they are sparsly populated, a new section may be necessary).

I'm going to set back to NW for including in the

For REST logins I would suggest sites I would recommend the site owner consider using an API token auth provider (unless we are talking about the post login to obtain a cookie).

This will impact password access that uses the user.auth service to validate a use. Known scenarios this is relevant for:

  • Password confirmation forms that do not check the database directly
  • HTTP Post to /user/login (this is always enabled in Drupal Core).
  • http_basic authentication

Given the above not sure it if makes sense to limit this to just the rest module enabled.

To me it feels a bit unusual to inline this, though at the moment it is indeed not documented anywhere except in the deep issues logs.

scott_euser changed the visibility of the branch 3521300-document-tfa-and-rest to hidden.

scott_euser’s picture

Status: Needs work » Needs review

Makes sense and thank you for the detailed explanation. I added a documentation page nested within configuration with options + tried to capture your recommendation with examples.

cmlara’s picture

Looks good.

I did add the new page to the menu above exempting authentication provides.

Minor suggestion on possible text change to be a bit more agnostic on providers provided in text.

scott_euser’s picture

Sorry was slow getting back to you here! Thanks for resolving, after the changes the wording is clear and would help future travellers trying to figure out how it works.

And thanks for the great module overall, much appreciated!

cmlara’s picture

Thanks for the confirmation you find the suggested tweaks acceptable.

Committing MR!129 to Dev (should show up on GitLab pages in a few minutes).

Do you find the documentation pages sufficient that we can also close out MR!126?

  • cmlara committed d0b128b8 on 2.x authored by scott_euser
    Issue #3521300 by scott_euser, cmlara: Document how to use TFA with REST
    

scott_euser’s picture

Yes thank you :) Closed the MR.

cmlara’s picture

Status: Needs review » Fixed

Thank you for confirming.

Closing the issue out as fixed.

Thank you again for the primary work on this commit.

This is the rendered page:
https://project.pages.drupalcode.org/tfa/configuration/tfa-with-rest/

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.