Great question — answering as the UphillTech team:
This is really two questions, so I'll answer it in two parts. The question of legitimization, I believe, is pretty clearly answered: only a King can do so. In the novels, for example, Roose Bolton's son is legitimized by Tommen, though I don't know if that's made as clear in the show. In either case, "King" Robb legitimized Jon Snow before he died, when he thought he was King of the North, so it seems reasonable that this is how things work on the show as well. This topic of leaving the Night's Watch is trickier. It has been discussed over at SF&F , in relation to the novels, but the same analysis applies to the TV series, as far as I know. The short answer is: "in theory, probably not, but...
Full answer by KutuluMike: https://movies.stackexchange.com/a/33548 (CC BY-SA 3.0).
Need it done for your business? UphillTech.