There are indeed exceptions to that rule, but neither of your sentences fall into that category.
The rule doesn't apply to prepositional phrases, only to objects (direct and indirect) of the verb. Prepositional phrases follow different word order rules, depending on what they describe (e.g. in the order of time-manner-place). The rule really should be stated as "indirect objects come before direct objects".
Your first sentence, for example, really does follow the rule because the indirect object (ihrem Mann) comes before the direct object (einen Kuss). The position of the phrase auf die Glatze isn't handled by the rule you describe because it is a prepositional phrase.
Your second sentence has no indirect object at all, just a direct object (meine Freundin). Von der Wahrheit is neither a direct object nor indirect object.
I mentioned at the beginning that there were exceptions. That is when the direct object is a pronoun:
Er gibt mir das Handy.
Er gibt es mir.
You might also say it's an exception when you bring the direct object to the front for emphasis:
Das Handy gibt er mir.