Google Sign on in Team Edition


I need to implement Google sign on in Team edition. How do I go about it? I see that code is already there for it. There are however few checks in the code for the license. Can I modify those checks in the code to enable it in Team edition? Would that be permitted as per open source license agreement? If not, what is the right way to implement this? Can’t afford to buy E20 license for this.

Not sure what is the right way to go about it. Please help.