It is not flim-flam. The shareholders elect a board, and the board has to approve stock based compensation. The shareholders price shares based on this expected dilution so no one is being fooled and there is no sleight of hand. All of this is very public.
The flim-flam comes when management argues that they don't need to book a compensation expense. Happily, though, this flaw in the GAAP has long since been cured.