Er, no he wasn't
The Federation is not terribly fascist, for one thing, and the book is definitely not a parody from his point of view.
Heinlein was very much in favor of the military and quite the Libertarian as well.
Regards,
-scott
Welcome to Rivendell, Mr. Anderson.