The origins on this, uh, lovely term, are hard to pin down. Slang experts place it in the '90s, but it's not clear exactly where it came from. Credit might go to House of Pain, which referenced it in '92 on the track "Feel It." The line went like this: "And let's get down to do the nasty, freaky, funky, stinky, junky, let's bump uglies in the nighttime between the sheets." Considering "uglies" and "nasties" are kinda interchangeable, it's possible the members of House of Pain just started rattling off synonyms and landed on the phrase in question. Or someone might've noted that genitalia isn't that pretty before "Feel It" dropped. Hopefully, some noble linguist is on this very important case.
Get your freak on
This phrase was in use at least a decade before Missy Elliott got to it -- if you need evidence, look no further than LL Cool J's autobiography. People initially said "get your freak on" to refer to more perverted or kinky stuff (hence, "freak") but some used it as a more general catch-all term. Nowadays, either is acceptable, but spelling it "get ur freak on" is only OK if you're Missy.