The Buddhist faith did indeed enter China during the Han Dynasty. Scholars are not completely sure when it first got to China, but it is believed to have been some time in the first century of the Common Era.
The Han Dynasty had no problems with Buddhism. It did not try to resist Buddhism at all and the faith spread fairly rapidly in China. Scholars believe that Buddhism took hold more strongly and quickly among the elites of the northern parts of China and then spread to the South and to other parts of society.
The Chinese are said to have adopted Buddhism quite easily because the Buddhist faith was compatible with (and willing to adapt to) indigenous Chinese religions. Buddhism typically became somewhat synthesized with both Taoism and Confucianism and thereby managed to make its way quite easily into Chinese culture.