Without knowing the specifics of your credit card processing setup, I can't say for sure if the right answer to that question is yes or no, but most likely card data is not stored locally until the batch is settled. In most merchant POS setups, when you swipe or enter a card, it's encrypted and sent to your merchant processor who will keep that transaction data until it is time to submit and settle rather than stored on any computer or device at your location.
That said, I've had luck in the past justifying the presence of that service by stating something like the following:
Please grant an exception for the open service on TCP port 50001.
- This service supports TLSv1.2 and devices accessing this service explicitly use TLSv1.2.
- Access to this port is restricted to a certain IP address space.
- Access through this port requires authentication.
- Credentials allowing access through this port are changed frequently.
If you can confirm whether or not it's true, you can also say that you do not store any cardholder data and only transmit encrypted payment card data.
If the scan vendor can't issue you an exception based on the above statements, support can disable this port for you. It is used by Sonic for remote management and router troubleshooting. If the port is disabled and you need support, we may require that you factory reset your modem which would lose any custom settings. You may also be able to bridge your modem/router and install a business grade router to connect your network to as well.
In regards to port 6319, this is not normally open so you may want to check the router's settings for any port forwards and find out what that's for or if it can be disabled. I'm fairly certain this due to a port forward that is unrelated to your Sonic service.