Announcement

Collapse
No announcement yet.

Ability to respond with custom response code from Authentication class

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Ability to respond with custom response code from Authentication class

    Greetings

    Use case: We are developing a custom authentication class that extends:
    Code:
    com.mirth.connect.plugins.httpauth.Authenticator
    This class will retrieve the Bearer token from Auth header and will verify it as jwt token using issuer and audience. When coding this I didn't see a way to configure a different response code for failed scenarios other than 401. We need it to be 403 in some cases.

    I pulled latest code from mirth github just a day before 3.12.0 was released and verified that in fact 401 is hard coded.

    For this purpose I have created this ticket on github: https://github.com/nextgenhealthcare...ct/issues/4776

    A work around solution might be to address this using filter code but it is not elegant and not ideal.

    Question is this, have anyone else had such a use case as us and if so how did you solve it?

    Thanks
    Pavel

Working...
X