Actually, citizenship of the Federation is typically required to enter into Starfleet, however there is a procedure to bypass this requirement on a case-by-case basis:
NOG: That's right. I want to be the first Ferengi in Starfleet. Now, who do I see about getting a uniform?
SISKO: Nog, if you want to become a Starfleet Officer, you have to attend the Academy.
NOG: All right. Where do I sign up?
SISKO: It's not that simple. As a non-Federation citizen, you need a letter of reference from a command level officer before you can even take the entrance exam.
NOG: A command level officer? You mean, like you?
SISKO: Well, yes. Like me.
NOG: Then you'll write the letter.
SISKO: I'll think about it.
NOG: Thank you, Commander. I know you'll make the right decision.
SISKO: Aren't you forgetting something?
NOG: Keep it. Consider it a token of my appreciation.