Place the chillies in a roasting tray and rub them with olive oil. Roast them in the oven until golden. ( You can roast the garlic cloves too, unpeeled).
Transfer the roasted chillies to bowl, put a lid on, and let them sweat. When cool, remove the stalks of the chilli (and the skin if you like) and the seeds, if you don’t want the paste to be too spicy. (I normally leave the seeds in and the skin on).
Put the chillies in a food processor together with the cooking juices. Add the garlic - roughly chopped, if raw, or scraped out of their skin, if roasted. Add salt, lemon/lime juice and tomato purée. Whiz until smooth.
Transfer to an airtight jar. Chill in the refrigerator.