Skip to content

Commit

Permalink
v1.4.2 checking entered terminal and PIN key values to be [^a-fA-F0-9]
Browse files Browse the repository at this point in the history
  • Loading branch information
timgabets committed Jan 18, 2018
1 parent 26e814e commit 6afb8ca
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
January 2018
1.4.2 checking entered terminal and PIN key values to be [^a-fA-F0-9]

December 2017
1.4.1 clearButtonClasses() and clearIconClasses() refactored
1.4.0 Removed duplicated code from src/listeners/settings.js
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "electron-atm",
"productName": "Electron ATM",
"version": "1.4.1",
"version": "1.4.2",
"description": "A simple APTRA Advance NDC ATM emulator",
"main": "main.js",
"scripts": {
Expand Down
6 changes: 4 additions & 2 deletions src/listeners/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,12 @@ $(function(){
setInterval(function(){
if(keys[type] !== $('#settings-' + type + '-key').val()){
keys[type] = $('#settings-' + type + '-key').val();


keys[type] = keys[type].replace(/[^a-fA-F0-9]/g,'');
$('#settings-' + type + '-key').val(keys[type].toUpperCase());

if(keys[type].length === 32){
$('#settings-' + type + '-key-cv').val(crypto.getKeyCheckValue(keys[type]));
$('#settings-' + type + '-key').val(keys[type].toUpperCase());
} else {
$('#settings-' + type + '-key-cv').val('');
}
Expand Down

0 comments on commit 6afb8ca

Please sign in to comment.