In a large skillet, cook the olive oil, garlic and rosemary over medium-low heat until golden, about 5 minutes. Add the beans and stir to coat. Season to taste with salt and pepper and cook for a further 5 minutes
Remove from the heat and mash the beans with a potato masher until almost smooth. Add the cheese and vinegar and stir to combine. Cool completely in the fridge until the mixture is firm, about 1 hour
To make the red pepper mayo, place the garlic and red peppers in a mini food processor or blender and pulse to mince. Add the mayonnaise and blend until smooth. Season to taste with salt and pepper and refrigerate
Roll rounded tablespoonfuls of the chilled bean mixture into balls. Roll each ball in the breadcrumbs, coat evenly in the egg mixture and roll again in the breadcrumbs.
Transfer to a tray lined with parchment paper. Repeat with the remaining mixture and chill in the fridge for 10 minutes
In a large skillet, heat ½-inch of the vegetable oil over medium heat until shimmering
Add half of the croquettes and fry, turning occasionally, until the crumbs are golden brown and crispy, about 7 minutes. Drain on paper towel and serve with the Red Pepper Mayo
*For dried beans, place ½ cup beans in a bowl and cover with a few inches of water. Cover and set aside for 8 hours or overnight. Drain, transfer to a medium saucepan, and cover with 2 inches cold water. Add half an onion and a bay leaf and bring to a boil, skimming any foam from the surface. Reduce the heat and simmer, stirring occasionally, until the beans are tender, about 1 hour. Stir in a pinch of salt and cook for a further 30 minutes. Discard the onion and bay leaf, drain, and proceed with the recipe.