In the US, your employer can forbid you from revealing your pay to outsiders, but the National Labor Relations Act guarantees that employees have the right to discuss their pay with one another. (I believe this falls under the heading “you have the right to discuss with your co-workers whether or not your job sucks so much that you should try to organize a union.”)