Seems like a more robust solution would be to just fix the bad bankruptcy laws instead of "regulating" every possible variant of "company has custody of X which is actually owned by customer Y". There ought to be a simple way to declare: "this is not company property and is off limits to company creditors in the event of a liquidation".
These aren’t bad bankruptcy laws. They are actually good and protect things that are most important- bondholders and higher priority creditors.
I don’t think letting companies set their own creditor priorities would really be feasible if we want to have predictable securities markets.
I assume that if we let companies protect certain assets from creditors during bankruptcy they would set aside massive bonuses and all sorts of other shenanigans.