Boil the beans for about 30-40 minutes and then strain.
Smash with a fork, or for a smoother patty mix in food processor.
Add the rest of the ingredients (except flour) and mix well. Knead with hands until all ingredients are well incorporated. Cover mixture and let it sit in the refrigerator for at least an hour (you can leave it overnight).
Form small patties (make them flat, not little balls) and cover them with a bit with flour.
Heat olive oil in a large pan (about an ½ inch high).
Once oil is hot (do not let it burn or smoke) add the patties, and fry on both sides until golden. For about 4 minutes total.