In general, your registered party is part of your state voter registration. Some states use that to determine which primary you can vote in (“closed primary”), while others let you choose a party at the time of voting (“open primary”). Either way, though, voting in both parties’ primaries is operated by the state as part of a unified process, at the same location; so it shouldn’t be possible to vote more than once.
If you’re in a caucus state, that process might be different; I’m not sure.
If you’re in a caucus state, that process might be different; I’m not sure.