Do you want WordPress users to be able to log into XenForo?
In this case WordPress needs an OAuth provider Plug-in like
[URL unfurl="true"]https://wordpress.org/plugins/oauth2-provider/[/URL]
[URL unfurl="true"]https://wordpress.org/plugins/miniorange-oauth-20-server/[/URL]
Furthermore, XenForo needs an OAuth2 Connected Account provider class that can communicate with this endpoint.
This most likely would require custom development, at least with XenForo 2.0-2.2 - if this is still the case with XenForo 2.3 depends a bit on the used OAuth2 Client library.
Why does this need custom development, can't there be a "generic" OAuth2 client?
OAuth2 only specifies how to authorize a user, it does not specify how to actually get information about the user (ID, username, email, etc.), so this is specific to each provider.
The provider implementations XenForo offers are built for specific providers (Microsoft, Googe, Facebook, etc.) -there is (currently) no class that is fully configurable.
Or do you want XenForo users to be able to log into WordPress?
In this case WordPress needs an OAuth2 Client plugin that is either a) fully configurable regarding API URLs and returned data or b) built specifically for XenForo.
I am not that familiar with WordPress but from reading it seems like https://wordpress.org/plugins/miniorange-login-with-eve-online-google-facebook/ might be able to do that.