It's possible to sell salvaged ships.
As for the confiscation I am not so certain. There are several things to consider:
1) You got a free ton of weapons/techgoods for a single roll, and you lost it by a single roll
2) Routine inspections don't happen that often
3) You can saveguard against this by buying cargo shielding and you could also sell the parts on a planet
But you gave me an idea for a new Item: Blank cargo docs. Could be sold by some of the seedier individuals in the sector, or obtained by doing quests for station commanders and merchants. I can imagine them working in two ways. You quickly fill one out when the inspection comes aboard, or you need to do it in advance.
They would be rather cheap but not that easy to get, since you are not supposed to have them
![smile :)](./images/smilies/icon_e_smile.gif)