Source: https://cis.temple.edu/~wu/teaching/Spring 2013/handoff.pdf