Details

    • Type: New Feature
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0
    • Fix Version/s: 1.3
    • Component/s: HTTP Interface
    • Labels:
      None
    • Skill Level:
      New Contributors Level (Easy)

      Description

      On a successful cookie-auth login (POST to _session), CouchDB will redirect the user to the URI specified in the 'next' query parameter. This is useful for adding authentication to applications that can't rely on javascript being enabled on the client. To make this functionality more useful, there should be a complimentary 'fail' redirect.

        Activity

        Hide
        mcooley Matt Cooley added a comment -

        Patch adds support for specifying a redirect in the 'fail' member of the query string.

        Usage:
        POST 'name=

        {username}

        &password=

        {passsword}

        ' to
        _session?next=/redirect/here/on/success&fail=/redirect/here/on/fail

        Tests included.

        Show
        mcooley Matt Cooley added a comment - Patch adds support for specifying a redirect in the 'fail' member of the query string. Usage: POST 'name= {username} &password= {passsword} ' to _session?next=/redirect/here/on/success&fail=/redirect/here/on/fail Tests included.
        Hide
        janl Jan Lehnardt added a comment -

        I like the patch & tests, but it no longer applies to trunk. Can you update the patch?

        Show
        janl Jan Lehnardt added a comment - I like the patch & tests, but it no longer applies to trunk. Can you update the patch?
        Hide
        simleb Simon Leblanc added a comment -

        I updated the patch.

        (I didn't change a thing but I used the latest rev from trunk)
        Hope it helps!

        Show
        simleb Simon Leblanc added a comment - I updated the patch. (I didn't change a thing but I used the latest rev from trunk) Hope it helps!
        Hide
        simleb Simon Leblanc added a comment -

        I don't know why I sent a svn patch… Here is the git one!

        Show
        simleb Simon Leblanc added a comment - I don't know why I sent a svn patch… Here is the git one!

          People

          • Assignee:
            Unassigned
            Reporter:
            mcooley Matt Cooley
          • Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 0.5h
              0.5h
              Remaining:
              Remaining Estimate - 0.5h
              0.5h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development