In this paper, we consider the canonical transformations and its applications appearing in astrodynamic problems. First we address stabilization of relative motion via generalized canonical transformation and passivity-based control. Then we propose a method to solve Lambert's problem based on the Hamilton-Jacobi-Bellman (HJB) equation in optimal control theory. Using the generalized canonical transformation, we transform the performance index to positive- definite one and then solve the optimal control problem. We also apply our method to obtain solution to two-point boundary-value problem by the generating function. As an application of the generating functions approach, we consider the problem of multiple flyby mission with impulsive thrust.