While some may claim this is a matter of opinion, it is fairly well-documented that most western cultures generally consider it crass, or "tacky" to discuss their salary. Certainly, in my home country of the United Kingdom, I know this to be the case. This article from Business Insider discusses how other countries feel about it, and apparently most European nations seem to feel the same way.
However, "rude" and "tacky" are not the same thing. There is rarely an excuse for being rude in polite company, but there may be certain contexts when discussing things like salary could be justified or, at the very least, excused.
Talking in public about one's income, particularly if it seemed you raised the subject deliberately, would generally be seen as bragging. Even if the amount of your income was very low, there are some who look down on "pleading poverty" as just a different means of drawing attention to oneself.
However, it is only really talking about the amount of one's salary that is considered crude, not talking about the concept of remuneration itself. If, for example, you wanted to relate an anecdote about asking your employer for a pay rise, you could likely do this without mentioning the starting salary, the amount of the raise, or your final salary. In the right context, this might be acceptable.
I wouldn't worry excessively about your mentioning it to your hairdresser. If it was not your intention to brag then the chances are that is not how it would have come over to them. If you are young, allowances are also likely to be made for your inexperience. I would say it is highly likely they will not remember the conversation for long, as hairdressers make constant small-talk with dozens of customers every day, and this sort of thing must surely come up. In a genuinely haughty person it would probably come over a whole lot worse than your innocently mentioning it. My hairdresser asks me the same questions every time I visit - am I going anywhere for the summer, or what are my plans for Christmas. I tell him the same thing every time and still the same question. Even if there is a chance they do remember you, just make it your goal to avoid the subject again. If someone has a wrong impression of you, the best way is often to show over time that they are wrong, rather than argue a case. If you are normally a humble person, they won't hold any judgement against you.