Preheat the oven to 375°. In a small bowl, whisk the dulce de leche with the two mustards, and the garlic and cayenne. Whisk in 1/4 cup of the stock.
Trim the skin off the ham, leaving a 1/4-inch-thick layer of fat. Score the fat in a shallow cross-hatch pattern. Spread the onion slices in a large roasting pan. Set the ham on top and add 1/2 cup of the stock. Cover the ham with parchment paper, then cover the roasting pan with foil. Roast the ham for 1 1/4 hours.
Remove the foil and parchment, brush the ham with all but 1/4 cup of the dulce de leche glaze. Roast the ham for 1 hour longer, or until nicely glazed all over. Transfer the ham to a cutting board and let rest for at least 15 minutes.
Meanwhile, pour the pan drippings into a small saucepan and skim off as much of the fat as possible. Set the roasting pan over 2 burners. Add the remaining 1/2 cup of stock and cook, scraping up any browned bits from the bottom and side of the pan. Pour the deglazed liquid into the saucepan. Whisk in the remaining 1/4 cup of dulce de leche glaze and bring to a boil. Transfer the gravy to a warmed gravy boat. Thinly slice the ham and serve with the gravy.