But for selling software, if you were truly benevolent, wouldn't you give it all away for free? Denying people who can't pay reduces the good you are doing - doesn't it?
Maybe an answer is that there's nothing wrong when people pay - because then they do get the value you created. It's only an issue when people cannot pay, and you deny them, because it's only in that case that your potential for doing good is unfulfilled.
I think the latter case only happens when (1) your prices are too high for the value particular users get from your software; or (2) too high for their wallet.
I think the solution to the first problem is to price your software (roughly) in proportion to the value customers get from it. E.g. "per seat" or "per server" or "volume-base" pricing does this. It's better to under-price than overprice (in reality, there's a huge range of values that customers get from a product, some get much more value from it than others - if you price too low, some get a fantastic bargain; too high, and you deny some).
For the second problem, some kind of charity version is appropriate, where you give it away to someone who just can't afford to pay for the value they would get from it. e.g. student versions. In economic theory, a loan would probably be appropriate; but a gift is nicer and simpler.
These problems become simple if your software actually helps people earn or save money themselves - then it's a non-issue that they can and should pay for it.
essay: http://paulgraham.com/good.html
video: http://www.omnisio.com/startupschool08/paul-graham-at-startu...)