The band extractor is not working properply.
It does not copy the flag band on which the masks are based on. Each flag defines a mask.
And if you have used the land/sea mask operation to apply the shapefile then you had bad luck again. This one does not handle the masks at all. And it’s not its intention.
It just changes the data of the selected bands.
If you want to use the result of it, you need to merge with the original data. The merging can be done by another operator, named ‘Merge’, available in the GraphBuilder and on the command line or you can use the band math to copy a band from one product to another.
The question is actually why do you need the masks as bands.
Do you need them in another application?
Then the suggestion Andreas made is proberbly the best. Turn them into a band via the band math. Or you can use the flag band ‘pixel_classif_flags’ and check which bits are set for each pixel, if this is doable in the other application.