Until you've got some kind of budget authority or are part of a purchasing approval process, you're unlikely to run into this problem, but it's best to be aware of it. The situation is simple: A salesman who is trying to sell your company a product (or service) gives you something either before or after the sale. Is it a gift or a bribe?
So let's dispense with two easy cases. The salesman takes you out to lunch and pays for the lunch. Maybe even an expensive dinner. No problem. This is totally within the realm of expectations and normal behavior in most industries. Few people are going to be bought off by the price of a meal. Now easy case number two: The salesman gives you a cash 'rebate' equal to 10% of the contract price. That's a kickback and it's illegal. At least in the US, although it may be standard procedure in other companies. Between these two cases lies the huge grey area.
Certainly one variable is the amount of the gift. If it's relatively small compared to the product cost, it's probably ok. But absolute dollars matter too. It's not ok to accept a $50,000 car from someone selling your company $10,000,000 worth of hardware, even though the gift is a small fraction of the contract.
It also depends on the industry in which you work. Many companies reward their best salespeople - and their clients - with lavish vacations at expensive resorts. Of course, they call them business development meetings and maybe they'll have product announcements or training. If it's accepted practice in your industry, it's probably ok. But it looks fishy from the outside. The pharmaceutical industry is under a lot of pressure to stop wooing doctors with product informational meetings held in exotic places.
If you work in the government or military, on the other hand, you will be severely restricted on the types of gifts you can accept. And rightly so, since the money you spend is the public's money. In the military where there is (and as been) the opportunity for tremendous abuse in the purchasing of billions of dollars of products, only the most trivial gifts are allowed.
Gifts for the whole office, like a fruit basket during the holidays, are usually exempt from scrutiny.
If the gift is somewhere in the grey area, I think you should ask yourself whether it feels like a bribe or would look like a bribe to a outsider. It's also something you can discuss with your boss, at any level. (If you don't want to reveal the gift to your boss, it means you probably shouldn't accept it in the first place.) Personally, I would err on the side of caution. Politely return the gift and thank them for the thought. You'll sleep better.