Heat olive oil in pan and sauté onions over medium heat til golden. Add prosciutto and allow it to melt into the oil. When everything has had a chance to blend together, add the pepper and beans, mashing some of the beans into the mixture. Mix well and add a generous glass of wine. Add the rosemary, a small branch of fresh rosemary if you can find it and two soup spoons of tomato paste if you like.
Cover beans with broth or water, bring to a boil, then reduce heat to low and continue to cook, partially covered. When the beans start to get tender, take about half of them out of the pan, mash them, put them back in the pot and continue to cook over low heat. The soup will have the thickness of the mashed beans and the texture of the whole beans. Take out the prosciutto. It has already flavored the soup, and if you want, eat it. If the soup seems too thick, add more water. During the last few minute of cooking, add broken pasta pieces. After about 30 minutes, when everything smells right, serve the soup with a little olive oil on the top.