This is true assuming the value of the security cannot go negative. If you sell the put, the worst that can happen is that the security will be worthless at expiration, in which case your counterparty will exercise their option to sell it to you at $K,$ which results in a loss of $K$ for you. If you collected more than $K$ in premium, you still win, even in the worst case scenario, so it's an arbitrage opportunity.
(And you get the premium up front and take the losses at expiration, so you also earn interest on the premium.)