In this paper, we present a chaotic image encryption algorithm in which the key stream is generated by nonlinear Chebyshev function. The novel method of designing pseudorandom chaotic sequence is carried out with the created secret keys depending on with each other. We then make multiple permutation of pixels to decrease the strong correlation between adjacent pixels in original plain image. Further, a two-dimensional Chebyshev function is considered to avoid known-plaintext and chosen-plaintext attacks in diffusion process, i.e., even with a one-bit change in original plain image, the encrypted image would become different greatly. Simulation results are given to show that the proposed method can offer us an efficient way of encrypting image.