IGR J18179-1621 is a hard X-ray binary transient discovered recently by INTEGRAL . Here we report on detailed timing and spectral analysis on IGR J18179-1621 in X-rays based on available INTEGRAL and Swift data . From the INTEGRAL analysis , IGR J18179-1621 is detected with a significance of 21.6 \sigma in the 18–40 keV band by ISGRI and 15.3 \sigma in the 3–25 keV band by JEM-X , between 2012-02-29 and 2012-03-01 . We analyze two quasi-simultaneous Swift ToO observations . A clear 11.82 seconds pulsation is detected above the white noise at a confidence level larger than 99.99 \% . The pulse fraction is estimated as 22 \pm 8 \% in 0.2-10 keV . No sign of pulsation is detected by INTEGRAL/ISGRI in the 18–40 keV band . With Swift and INTEGRAL spectra combined in soft and hard X-rays , IGR J18179-1621 could be fitted by an absorbed power law with a high energy cutoff plus a Gaussian absorption line centered at 21.5 keV . An additional absorption intrinsic to the source is found , while the absorption line is evidence for most probably originated from cyclotron resonant scattering and suggests a magnetic field in the emitting region of \sim 2.4 \times 10 ^ { 12 } Gauss .