channels/smartcard: improve parsing