Back in the good old days we as cabin crew would announce that "photography is strictly prohibited at......." But then there were no smart. Many civil airports double up as military bases as well, hence the ban.
I guess the answer is depends on where you are, whose around to say no or whose back is turned while you get a sneaky shot.