Something went weird during a rebel mission in Luna where I get the cloaking device. I succeeded delivering the agents but then I was told to go to Mars and there, this guy offered me a mission to deliver weapons to a pirate planet and I think I was caught by the confeds. I bribed my way back to Mars and Luna and nothing… Will I get the original mission back?
Welcome to the boards, Maharal.
Yes, you should be able to pick up that mission on Mars, though it will take a few tries because EV missions are only available about 20% of the time. So... if Mars won't let you land you might have to bribe your way a few more times, or take out some Pirates (or even Rebels) to make the Confeds like you again. If it were me, I'd head to the closest uninhabited system and spend some time looting Pirates. That way you make money and your rating with the Core Systems will improve, eventually. Good luck.