Because NASA isn't just free do things with that knowledge even if somebody could pay. You live in a total fantasyland when you believe that NASA just having some IP does any good for anybody.
You need manufacturing base and a business model to sustain commercial operation. NASA is a government agency that gets its priority sets by a congress that is not very interested in space flight, and putting the budget wherever they want at any given time. So NASA could have lots of IP about 4 different vehicles that gets into LEO but no amount of money could actually get you there.
They can give the IP to a 3rd company of course, but because they way it was designed it would not really have any commercial use, and likely it only works connected together with other government IP/hardware that you also easily get.
Now you have a private company, who has a very clear business intensive, to get the greatest possible use out of that IP, it only uses other commercially available tools and has synergy with other parts of their business that also has other commercial uses. The industrial base and teams are sustained, and not removed when congress lowers budget for a year.
So the Dragon 2 works with Falcon 9 rocket. SpaceX always operates Falcon 9 launch pads and they have plenty of rockets to fly and a manufacturing base that makes more of them. So now you have a much easier time to get the whole system together for an actual 3rd party flight, as the rocket, launch pad, infrastructure is already there and commercially operated.