Similarly to Sean I have used a door for that. But I didn't hang on the door itself, but jammed some bit of cloth (some thin trousers) into the door by draping it over it and then closing it. This is very stable and gives you a movement like pulling on rings or a rope. You can then vary your body angle and make it as strenuous as you wish to. It is not a pure pull-up motion, more a front pull, but better than nothing when traveling.
It is probably wise to make sure that nobody can open the door from the other side (i.e. do not do it in a door that opens to some public space where someone could come in anytime...).
This is quite nice even in hotels and basically everywhere you have a towel or a pair of robust trousers etc.
At home I have hung a "fingerboard" (a.k.a. "hangboard") over a door frame. I am training for rock climbing, but I guess anyone could use those - even if you do not want to train your small forearm muscles you can find some that have big holds ("jugs"), and they are great for pullups; you can also simply DIY some wooden blocks for that (make them round and only semi-smooth, not too much that you slip, but so that they don't hurt your fingers). By screwing those on the wall above the open door (with very substantial screws, possibly heavy duty anchors), you get the full benefit of hanging and pulling freely on one or two hands, without requiring an actual pullup bar somewhere.