• Resolved arjunmurali1993

    (@arjunmurali1993)


    Hi,

    We see in the admin panel when loading certain plugins that they don’t work correctly. In the console, there is a javascript error caused in the select2.min.js file present inside the oauth2-provider plugin folder.

    Screenshot: https://ibb.co/y6gjM9g

    Could you please help resolve this?

    Regards,
    Arjun

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Justin Greer

    (@justingreerbbi)

    We are working on a release that will fix this issue. The fix is to only load select2 on client pages. The fix will be in the next release shortly.

    Thread Starter arjunmurali1993

    (@arjunmurali1993)

    Hi,

    We just installed the new version of the plugin and the error went away.

    However, on our Angular application that uses the OAuth Authentication provided by your app, it shows there has been a critical error on the website.

    Screenshot: https://ibb.co/61xhm6Q

    I’m reverting back the previous version of the plugin since it’s a live application used by hundreds daily.

    Can you please look into this?

    Regards,
    Arjun

    Plugin Author Justin Greer

    (@justingreerbbi)

    Thank you for reporting back. Are you able to provide and error from the server log for this issue? The error for provided by WordPress is a generic error but does not provide feedback as to what it could be.

    There will be an error in your server logs that should help track it down. Let me know and I will be sure to help get it straightened out.

    Thanks

    Thread Starter arjunmurali1993

    (@arjunmurali1993)

    Hi,

    Could you please explain or share some link which will guide me to retrieve the WordPress Server logs that you mention?

    I’m not too familiar with how WordPress works. My apologies.

    Regards,
    Arjun

    Plugin Author Justin Greer

    (@justingreerbbi)

    Please try to update to the latest version. Version 4.1.5 now contains a DB version check that will address the issues we think you were experiencing.

    Thread Starter arjunmurali1993

    (@arjunmurali1993)

    Hi,

    I tried after updating to version 4.1.5 but getting the same ‘critical error on website’ error when trying authenticate from our Angular application.

    Have reverted back to 3.8.1 for the moment and it is working fine. However, the Javascript error does happen and prevents certain other plugins from working.

    Regards,
    Arjun

    Plugin Author Justin Greer

    (@justingreerbbi)

    Ok. Sorry again for the issues. We really need to see the server logs to see what is going on. If you contact your host, they can point you in the right direction.

    Once we have the error that is causing the issue, we can then track down the issue.

    Thread Starter arjunmurali1993

    (@arjunmurali1993)

    Hi,

    I enabled debug mode and got the following error when trying to authenticate from our Angular app. Plugin version 4.1.5

    
    Warning: file_get_contents(/var/www/html/wp-content/uploads/wo-keys//private_key.pem): failed to open stream: No such file or directory in /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/ResponseType/JwtAccessToken.php on line 124
    
    Warning: openssl_sign(): supplied key param cannot be coerced into a private key in /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/Encryption/Jwt.php on line 114
    
    Fatal error: Uncaught Exception: Unable to sign data. in /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/Encryption/Jwt.php:115 Stack trace: #0 /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/Encryption/Jwt.php(100): WPOAuth2\Encryption\Jwt->generateRSASignature('eyJ0eXAiOiJKV1Q...', false, 7) #1 /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/Encryption/Jwt.php(16): WPOAuth2\Encryption\Jwt->sign('eyJ0eXAiOiJKV1Q...', false, 'RS256') #2 /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/ResponseType/JwtAccessToken.php(130): WPOAuth2\Encryption\Jwt->encode(Array, false, 'RS256') #3 /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/ResponseType/JwtAccessToken.php(78): WPOAuth2\ResponseType\JwtAccessToken->encodeToken(Array, 'RZsVRv1GpWVkuSg...') #4 /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/ResponseType/AccessToken.php(52): WPOAuth2\ResponseType\JwtAccessToken->createAccessToken('RZsVRv1GpWVkuSg...', 1, 'openid', fals in /var/www/html/wp-content/plugins/oauth2-provider/library/WPOAuth2/Encryption/Jwt.php on line 115
    
    There has been a critical error on your website.
    

    Is this what you are looking for? If there is sensitive info in the above log, can you please delete the message after reading it?

    Regards,
    Arjun

    Plugin Author Justin Greer

    (@justingreerbbi)

    @arjunmurali1993 Thank you for sharing this. There is nothing sensitive here so you are safe.

    If this is the error that is causing the issue on your server then as basic as this sounds, please visit the “Server Status” page in the plugin’s settings area. You should see the certificates listed. If not, click the regenerate button.

    Thread Starter arjunmurali1993

    (@arjunmurali1993)

    Thanks, Justin. Everything got fixed when I clicked on Regenerate Certificates and it’s working fine now.

    Cheers!

    Plugin Author Justin Greer

    (@justingreerbbi)

    Great news! Thank you for letting me know.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘WP Oauth Server Plugin is Crashing the Javascript on our Website’ is closed to new replies.