You won't even need a gate pass. The TSA will allow you into any terminal as long as you have a same day ticket to fly out of that airport. If they point out you're in the wrong terminal just say you want to use the lounge and that's good enough. Now of course you know you'll have to leave and take the shuttle bus to T4 and reclear security right?