  In this paper we describe a measurement technique capable of resolving
femtosecond X-ray pulses from XFEL facilities. Since these ultrashort pulses
are themselves the shortest event available, our measurement strategy is to let
the X-ray pulse sample itself. Our method relies on the application of a
"fresh" bunch technique, which allows for the production of a seeded X-ray
pulse with a variable delay between seed and electron bunch. The shot-to-shot
averaged energy per pulse is recorded. It turns out that one actually measures
the autocorrelation function of the X-ray pulse, which is related in a simple
way to the actual pulse width. For implementation of the proposed technique, it
is sufficient to substitute a single undulator segment with a short magnetic
chicane. The focusing system of the undulator remains untouched, and the
installation does not perturb the baseline mode of operation. We present a
feasibility study and we make exemplifications with typical parameters of an
X-ray FEL.
