I already have an existing codeigniter 4 oauth server using bshaffer oauth2 lib for PHP and I also want to implement firebase authentication mostly from flutter mobile app. I'm trying to check from ci4 filters if the header bearer is from flutter firebase idToken or from bshaffer oauth2. The reason is to run the specific verification either bshaffer or firebase verifyIdToken.
The only difference is my bshaffer token is exactly 40 characters and firebase idtoken is way longer.
Also I'm not really sure if this process is correct. But if you have better solution for adding firebase authentication to an exising restapi, please enlighten me.