• I get this problem when i try to use Course Review and Course wishlist add-ons through REST API.
    “‘lp_jwt_auth_bad_iss'”
    ‘The iss do not match with this server’

    This problem happens only with these two plugins but the LearnPress REST API itself works great. Also I didn’t face this problem before so I’m not sure what happened.

    I have LearnPress plugin: version 4.2.7.7.

    LearnPress – Course Review: version 4.1.5
    LearnPress – Course Wishlist Version 4.0.8

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter mhmdsalah

    (@mhmdsalah)

    Interesting, this problem happened after I installed Sublanguage plugin. I disabled it now and the problem fixed.

    Does anyone know why a problem like this might happens?

    Plugin Support brianvu-tp

    (@briantp)

    Hi mhmdsalah,

    Thank you for reaching out and providing such detailed information about the issue you encountered with the Course Review and Course Wishlist add-ons. We appreciate your thoroughness in troubleshooting the problem.

    We’ve also conducted tests with the same add-on versions you mentioned (LearnPress – Course Review 4.1.5 and LearnPress – Course Wishlist 4.0.8), along with the Sublanguage plugin, and haven’t been able to reproduce the “‘lp_jwt_auth_bad_iss'” error you described. Our tests were performed using the default Twenty Twenty-Five theme.

    Since the issue appears to be related to the interaction between the add-ons and the Sublanguage plugin, it would be very helpful if you could provide us with more information about your Sublanguage plugin setup. Specifically:

    1. Sublanguage plugin version: Knowing the exact version of Sublanguage you’re using will help us ensure we’re testing with the same configuration.
    2. Sublanguage settings: Could you please describe how you configured the Sublanguage plugin?
    3. Steps to reproduce the error: If possible, could you outline the specific steps you took to trigger the “‘lp_jwt_auth_bad_iss'” error? This will allow us to try and reproduce the problem on our end.

    Additionally, could you please try temporarily switching to the Twenty Twenty-Five theme on your site to see if the issue persists? This will help us rule out any theme-specific conflicts.

    We look forward to hearing from you and helping you resolve this issue.

    Best regards,
    Brianvu-tp

    Thread Starter mhmdsalah

    (@mhmdsalah)

    Hello, Thanks for the replay.

    Sublanguage version: ?2.12?

    This problem happens to me when i use the REST API of learnpress.

    To reproduce first make a request to the token endpoint to get the token:
    "/learnpress/v1/token"

    Then use this token to send request to any of the Course Review and Course Wishlist add-ons for example you can try this endpoint:
    "/learnpress/v1/wishlist/course/(?P<id>[\\d]+)"

    You will get:

    {
    code: "lp_jwt_auth_bad_iss",
    message: "The iss do not match with this server",
    data: {
    status: 401,
    },
    }
    Thread Starter mhmdsalah

    (@mhmdsalah)

    I use Twenty Twenty-Five theme. but I think the problem with REST APIs only.

    What I find strange is that the LeanPress endpoints itself are working great, the problem happen only with the add-ons.

    • This reply was modified 1 month, 2 weeks ago by mhmdsalah.
    Thread Starter mhmdsalah

    (@mhmdsalah)

    Here is all Sublanguage config

    Plugin Support brianvu-tp

    (@briantp)

    Hi mhmdsalah,

    Thank you for the detailed explanation and steps to reproduce the issue. We appreciate you taking the time to provide this information.

    The lp_jwt_auth_bad_iss error indicates a mismatch between the decoded JWT token’s iss (issuer) claim and the current site URL (obtained via get_bloginfo('url')).

    We’ve attempted to reproduce the issue locally using the Sublanguage configuration you described and then tested with the API endpoint wp-json/learnpress/v1/wishlist/course/COURSE_ID. Our tests, however, returned the expected results.

    Given this discrepancy, could you please double-check the URL you are using in your API requests? A slight error in the URL could potentially lead to the iss mismatch.

    Best regards,
    Brianvu-tp

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.