Just blurt it out. With friends you can always blurt it out. I have had friends hang up on me in disgust after realizing how they are getting shafted. But we are still friends. Better friends, now that they got their 40% increase... :P
Here is the thing. Salary secrecy is a Commercial Industrial Complex scam. This is how they keep us in the dark about how much we are worth. This is how they keep wages artificially low, so that the Man can have another private jet.
How they do it is by creating this phony social construct where it is somehow considered rude to talk money with your peers.
Whether the talk of money is considered bragging entirely depends on one's point of view. If you aren't bragging, your friends / peers won't perceive it as bragging.
And salary discussions inevitably leads to useful information exchange. Like how the heck are you making so much. OR why the hell are you making so little?
And if you are worried about your employment contract about disclosing your salary... Just lie. It is easy!
If you making $60,543.55 a year. Tell people you are making 61,000 or 60,000. I am 100% certain no employment contract ever says you can't lie about your salary. Luckily for us, most of us make a hard to remember sum, so it really shouldn't be too difficult to lie.
As for job searches, they almost always ask you what you are currently making (assuming you are currently employed). You should always lie. Here is the thing. If they didn't plan to low ball you with what you are currently making, they wouldn't even be asking the question.
Does a bad faith question deserve a good faith answer?