They all mean "in a short time" somehow. However, 临时 can be used in an unexpected situation. Check the sentences:
1. 我暂时有事。
2. 我临时有事。
暂时 implies that you have a plan for it. And you know it will continue for a short time.
临时 applies to a sudden situation. You may not be able to predict the time of its continuum.
(more)