Here in the Lower Rhine region those beans are called "saure Schneidebohnen" or " saure Schnippelbohnen" ( sour sliced beans). They are available at supermarkets packaged in 1 lb foil bags, having a recipe suggestion printed on it, because it starts to be an old-fashioned vegetable that many younger people don't know.
In pre-freezer times preserving the large summer crop of beans happened by sterilising them in jars or with the even older method of brining. The beans turn out rather sour and salty, so most poeple find it nessessary to wash them or even boil off some of the salt before use in a recipe. (This is not the case with the store-bought sour beans, they are fermented in a highly controlled environment with special very mild germs, a short rinse under the tap is usually enough. Same applies to sauerkraut, BTW).
I don't have any experience with brining, but will give you a recipe from my German Great-grandmother's cookbook with some comments that might be helpful. It uses wine leaves (I imagine it helps start the fermentation??).
Sliced Beanes in Salt
(No amounts of beans or salt are given, but old-fashioned crocks used to hold a gallon or two at least.

)
Choose a rather soft sort of beans, pull of the string (if they have any) and slice them rather finely (on the diagonal, 1/8 x 2 inch strips).
Cover the bottom of a crock with salt, put in a layer of beans, about 3 fingers thick, put enough salt on top to just cover the beans. Add anew layer of beans and salt and so forth, until all beans are used up.
On top of the last salt lyaer put a layer of wine leaves, on top of those a wooden board (usually fitting into the crock exactly) and weigh it down with stones.
Leave the crock in the cellar ( cool dark place away from people

).
After 10-14 days remove wine leaves and and the skin that will have developped on the beans.
Put a clean linen cloth (you can boil linen) on the beans and weigh down again with the board and stones.
From time to time the cloth and the board need to be cleaned, and care has to be taken that the beans are always completely covered with brine.
Before use beans must be well watered. When boiling, replace boiling water with fresh water several times. (There will not be left much nutrition in the beans then I suppose.)