Context. Low-mass stars are known to exhibit strong X-ray emission during their early evolutionary stages. This also applies to classical T Tauri stars (CTTS), whose X-ray emission differs from that of main-sequence stars in a number of aspects. Aims. We study the specific case of RU Lup, a well known accreting and wind-driving CTTS. In comparison with other bright CTTS we study possible signatures of accretion and winds in their X-ray emission. Methods. Using three XMM-Newton observations of RU Lup, we investigate its X-ray properties and their generating mechanisms. High-resolution X-ray spectra of RU Lup and other CTTS are compared to main-sequence stars. We examine the presence of a cool plasma excess and enhanced plasma density in relation to X-rays from accretion shocks and investigate anomalous strong X-ray absorption and its connection to winds or circumstellar material. Results. We find three distinguishable levels of activity among the observations of RU Lup. While no large flares are present, this variability is clearly of magnetic origin due to the corresponding plasma temperatures of around 30 MK; in contrast the cool plasma component at 2–3 MK is quite stable over a month, resulting in a drop of average plasma temperature from 35 MK down to 10 MK. Density analysis with the O vii triplet indicates high densities in the cool plasma, suggesting accretion shocks to be a significant contributor to the soft X-ray emission. No strong overall metal depletion is observed, with Ne being more abundant than Fe, that is at solar value, and especially O. Excess emission at 6.4 keV during the more active phase suggest the presence of iron fluorescence. Additionally RU Lup exhibits an extraordinary strong X-ray absorption, incompatible with estimates obtained at optical and UV wavelengths. Comparing spectra from a sample of main-sequence stars with those of accreting stars we find an excess of cool plasma as evidenced by lower O viii/O vii line ratios in all accreting stars. High density plasma appears to be only present in low-mass CTTS, while accreting stars with intermediate masses (2 M� ) have lower densities. Conclusions. In all investigated CTTS the characteristics of the cooler X-ray emitting plasma are influenced by the accretion process. We suspect different accretion rates and amounts of funnelling, possibly linked to stellar mass and radius, to be mainly responsible for the different properties of their cool plasma component. The exceptional X-ray absorption in RU Lup and other CTTS is probably related to the accretion flows and an optically transparent wind emanating from the star or the disk.