Hmmm, interesting that. Stop people in disguise? Don't think so. Presumably you can wear a false beard on a plane? Wonder what the logic, if any, is behind it?
What do they mean by not appear to be the gender? Are they going to look in our underwear? Do a genetic check? The more you think, the sillier this gets. So two people get on a plane, both wearing a T and jeans, security stop and say one of you cannot get on the plane because your outfit doesn't fit your gender. Now one is male and one is female, who is stopped? Both are female, who is stopped? Both are male, who is stopped? On is an MtF and the other an FtM, who is stopped? (I'm not gender dis-identifying here, it is an example of the issue).
Then we can start on ethnic groups. Scotsmen generally have a short fuse when they are told they are wearing a skirt.
An aside, the only time I checked what a Scotsman had under his kilt, I had my hand under his kilt and I said 'That's gruesome' He replied 'Aye Lassie, keep holding and it'll gruesome more'
Sorry 
But this 'law' seems to be totally unworkable and plain silly.
Cindy