We present a technique to measure lightcurves of time-variable point sources on a spatially structured background from imaging data. The technique was developed to measure light curves of SNLS supernovae in order to infer their distances. This photometry technique performs simultaneous PSF photometry at the same sky position on an image series. We describe two implementations of the method: one that resamples images before measuring fluxes, and one which does not. In both instances, we sketch the key algorithms involved and present the validation using semi-artificial sources introduced in real images in order to assess the accuracy of the supernova flux measurements relative to that of surrounding stars. We describe the methods required to anchor these PSF fluxes to calibrated aperture catalogs, in order to derive SN magnitudes. We find a marginally significant bias of 2 mmag of the after-resampling method, and no bias at the mmag accuracy for the non-resampling method. Given surrounding star magnitudes, we determine the systematic uncertainty of SN magnitudes to be less than 1.5 mmag, which represents about one third of the current photometric calibration uncertainty affecting SN measurements. The SN photometry delivers several by-products: bright star PSF flux mea- surements which have a repeatability of about 0.6%, as for aperture measurements; we measure relative astrometric positions with a noise floor of 2.4 mas for a single-image bright star measurement; we show that in all bands of the MegaCam instrument, stars exhibit a profile linearly broadening with flux by about 0.5% over the whole brightness range.