how to post magnatic stripe card reader data to aspx or ashx?
I am working on something that I have to first read the id number on a magnetic stripe card then post it to a login.aspx to login the website.
what sorts of techniques can I use for achieving that?
my first solution is (insecure)----:
save the data in a file when swipe the card, then use ActiveX control in a Javascript to read the file on clinet machine, then post it to the login.aspx
Stripe readers generally act like keyboards. The only real issue is dealing with carriages returns / newlines. The workaround can be something like a keylogging JavaScript (a Flash app or Java applet would work too). Just log the keystrokes until you hit your designated End-Of-Data marker or a pause in input significantly greater than that between "keystrokes" as configured in your reader.
EDIT: And then, of course, stuff the logged keystrokes into a variable for an AJAX request or a form field for a synchronous request [or a form field for an AJAX request].
Bookmarks