Shulchan Arukh, Orach Chayyim 586:19 says:
הִרְחִיק אֶת הַשּׁוֹפָר וְנָפַח בּוֹ וְתָקַע בּוֹ, פָּסוּל.
If he distanced the shofar from him and breathed into it and blew, it is invalid.
I'm not sure if this implies that one's mouth must always be on the shofar itself, or this deals with a specific case where one blows into the shofar from a distance, i.e. there is space (air) between one's mouth and the shofar.
Let's say one is uncomfortable with the shofar aperture or the hardness of the shofar resting on his lip. He wants to insert a straw or a rubber tube into the narrow opening of the shofar and blow into the straw or tube. Can he do this, halachically?