CN106294181B - Smart card software service life test method - Google Patents

Smart card software service life test method Download PDF

Info

Publication number
CN106294181B
CN106294181B CN201610715907.5A CN201610715907A CN106294181B CN 106294181 B CN106294181 B CN 106294181B CN 201610715907 A CN201610715907 A CN 201610715907A CN 106294181 B CN106294181 B CN 106294181B
Authority
CN
China
Prior art keywords
smart card
flash
simulated
environment
service life
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201610715907.5A
Other languages
Chinese (zh)
Other versions
CN106294181A (en
Inventor
张飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
CHENGDU SANLINGJIA MICROELECTRONIC Co Ltd
Original Assignee
CHENGDU SANLINGJIA MICROELECTRONIC Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by CHENGDU SANLINGJIA MICROELECTRONIC Co Ltd filed Critical CHENGDU SANLINGJIA MICROELECTRONIC Co Ltd
Priority to CN201610715907.5A priority Critical patent/CN106294181B/en
Publication of CN106294181A publication Critical patent/CN106294181A/en
Application granted granted Critical
Publication of CN106294181B publication Critical patent/CN106294181B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3664Environments for testing or debugging software
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3696Methods or tools to render software testable

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present invention relates to a kind of smart card software service life test methods, its main feature is that: flash is simulated by using byte array, using socket agreement, 7816 agreements is substituted and carries out data transmit-receive.Intelligent terminal can be simulated by wscript.exe, simulate specifically used mode and environment, final output is into file.Thereby, it is possible to the hardware environment of smart card is simulated by software under based on PC simulated environment.Can by test script come analog subscriber in the use environment of given time given situation, realize the simulation of use environments in more, save testing cost.Can intuitively see has what file and erasable number in each piece of flash, unreasonable place, analog parameter easy to adjustment in time are handled so as to positioning software fast and accurately.

Description

Smart card software service life test method
Technical field
The present invention relates to a kind of smart card life testing method more particularly to a kind of smart card software service life test sides Method.
Background technique
Smart card is seen everywhere in our life, such as bank card, bus card, mobile phone card, identity card etc., it has The advantages that safety, portability etc., it facilitates our life really.
It is well known that the use of smart card is also to have the service life.For hardware point of view, storage chip has certain wiping Write number.For software respective, within the set time, in the process using smart card, as long as guaranteeing erasable time of chip Number is no more than certain number, so that it may assert that software is normal.
For this purpose, software service life is improved, and the service life that smart card can be improved itself, so how quickly Accurately testing smart card software service life is also very important.
In view of the above shortcomings, the designer, is actively subject to research and innovation, to found a kind of smart card software use Life testing method makes it with more the utility value in industry.
Summary of the invention
In order to solve the above technical problems, the object of the present invention is to provide a kind of smart card software service life test methods.
Smart card software service life test method of the invention comprising following steps: step 1, by using byte Array simulates flash.Step 2 is substituted 7816 agreements and is carried out data transmit-receive using socket agreement.Step 3 passes through script Tool simulates intelligent terminal.Step 4 simulates specifically used mode and environment.Step 5 is output in file.
Further, above-mentioned smart card software service life test method, wherein in the step 1, will read and write The hal layer interface of flash, orientation resolves to read-write byte array, while defining long group array, is used for statistical simulation flash Every page of erasable number.
Further, above-mentioned smart card software service life test method, wherein in the step 2, by 7816 The hal layer interface of interface, orientation resolve to socket data, are received and dispatched.
Further, above-mentioned smart card software service life test method, wherein in the step 3, use band There is the wscript.exe of socket function, simulates intelligent terminal.
Further, above-mentioned smart card software service life test method, wherein in the step 4, by fixed Wscript.exe processed interacts situation statistics, it is written as corresponding script to simulate usage scenario.
Further, above-mentioned smart card software service life test method, wherein in the step 4, count Software writes script under specific time and specific occasion and the interaction scenario of intelligent terminal, with this.
Still further, above-mentioned smart card software service life test method, wherein in the step 5, definition is private There is instruction, long array is printed or oriented is output in file.
According to the above aspect of the present invention, the present invention has at least the following advantages:
1, the hardware environment of smart card can be simulated by software under based on PC simulated environment.
2, can by test script come analog subscriber in the use environment of given time given situation, realize in more and use Testing cost is saved in the simulation of environment.
3, it can intuitively see thering is what file and erasable number in each piece of flash, so as to quick and quasi- True positioning software handles unreasonable place, analog parameter easy to adjustment in time.
4, implement convenience, different scripts can be utilized, meet the needs of simulative debugging.
The above description is only an overview of the technical scheme of the present invention, in order to better understand the technical means of the present invention, And can be implemented in accordance with the contents of the specification, with presently preferred embodiments of the present invention, detailed description is as follows below.
Specific embodiment
With reference to embodiment, the embodiment of the present invention is furthur described in detail.Following embodiment is used for Illustrate the present invention, but is not intended to limit the scope of the invention.
Smart card software service life test method, unusual place be the following steps are included:
Firstly, simulating flash by using byte array.Specifically, the hal layer interface of flash, oriented solution will be read and write Analysis is read-write byte array.During this period, in order to realize more accurate statistics for erasable number, it can define long group number Group, for every page of statistical simulation flash of erasable number.
Later, using socket agreement, existing 7816 agreement is substituted, for example 7816T0 agreement carries out data transmit-receive.? During this, can the hal layer interface of 7816 interfaces be oriented and resolve to socket data, and be received and dispatched with this.
Then, intelligent terminal is simulated by wscript.exe.When actual implementation, for the ease of cooperating the simulation of PC machine It realizes, uses the wscript.exe with socket function of customization, simulate intelligent terminal.Later, specifically used mode is simulated And environment.During this period, in order to realize simulation identical with real use state, customizing script tool (foot can be passed through This tool can also have socket function), interact situation statistics.Finally, it is written as corresponding script to simulate Usage scenario.Further, it is possible to software be counted under specific time and specific occasion and the interaction scenario of intelligent terminal, with this To write script.
Finally, it is output in file.Specifically, it can define privately owned instruction, long array printed or oriented output Into file.
From the point of view of actual implementation of the invention, hardware environment, the communication protocols of smart card can be simulated by win32 program View, intelligent terminal etc..During this period, byte array can be used to simulate flash.The hal layer interface orientation parsing of flash will be read and write To read and write byte array, while defining the erasable number that long group array is used to every page of statistical simulation flash.
It can be seen that after applying the present invention by above-mentioned character express, gather around and have the following advantages:
1, the hardware environment of smart card can be simulated by software under based on PC simulated environment.
2, can by test script come analog subscriber in the use environment of given time given situation, realize in more and use Testing cost is saved in the simulation of environment.
3, it can intuitively see thering is what file and erasable number in each piece of flash, so as to quick and quasi- True positioning software handles unreasonable place, analog parameter easy to adjustment in time.
4, implement convenience, different scripts can be utilized, meet the needs of simulative debugging.
The above is only a preferred embodiment of the present invention, it is not intended to restrict the invention, it is noted that for this skill For the those of ordinary skill in art field, without departing from the technical principles of the invention, can also make it is several improvement and Modification, these improvements and modifications also should be regarded as protection scope of the present invention.

Claims (1)

1. smart card software service life test method, it is characterised in that the following steps are included:
Step 1 simulates flash by using byte array, will read and write the hal layer interface of flash, and orientation resolves to read-write Byte array, while long array is defined, for every page of statistical simulation flash of erasable number;
Step 2 is substituted 7816 agreements and is carried out data transmit-receive using socket agreement, by the hal layer interface of 7816 interfaces, orientation Socket data are resolved to, are received and dispatched;
Step 3 simulates intelligent terminal by wscript.exe, using the wscript.exe for having socket function, simulates intelligence eventually End;
Step 4 simulates specifically used mode and environment, by customizing script tool, interacts situation statistics, it is write Usage scenario is simulated at corresponding script;
Step 5 is output in file, counts software under specific time and specific occasion and the interaction feelings of intelligent terminal Condition writes script with this, defines privately owned instruction, long array prints or oriented is output in file.
CN201610715907.5A 2016-08-24 2016-08-24 Smart card software service life test method Expired - Fee Related CN106294181B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610715907.5A CN106294181B (en) 2016-08-24 2016-08-24 Smart card software service life test method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610715907.5A CN106294181B (en) 2016-08-24 2016-08-24 Smart card software service life test method

Publications (2)

Publication Number Publication Date
CN106294181A CN106294181A (en) 2017-01-04
CN106294181B true CN106294181B (en) 2019-02-01

Family

ID=57615324

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610715907.5A Expired - Fee Related CN106294181B (en) 2016-08-24 2016-08-24 Smart card software service life test method

Country Status (1)

Country Link
CN (1) CN106294181B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110568346A (en) * 2019-10-08 2019-12-13 东信和平科技股份有限公司 Aging test method and system for smart card

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114245367B (en) * 2021-12-14 2024-03-19 惠州Tcl移动通信有限公司 Method and device for automatically generating IMS smart card, mobile terminal and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1553327A (en) * 2003-05-30 2004-12-08 上海华园微电子技术有限公司 Circuit for testing EEPROM and testing method thereof
CN101413986A (en) * 2007-10-17 2009-04-22 北京中电华大电子设计有限责任公司 Method for testing reliability of smart card
CN102495797A (en) * 2011-11-25 2012-06-13 大唐微电子技术有限公司 Smart card testing device and method
CN102521178A (en) * 2011-11-22 2012-06-27 北京遥测技术研究所 High-reliability embedded man-machine interface and realizing method thereof
CN102521197A (en) * 2011-12-13 2012-06-27 福建鑫诺通讯技术有限公司 Method for realizing ISO7816 protocol with UART (universal asynchronous receiver/transmitter) of low-cost MCU (micro-control unit)
CN102567070A (en) * 2010-12-15 2012-07-11 沈阳新邮通信设备有限公司 Mobile phone software debugging method and simulator for mobile phone software
CN202351905U (en) * 2011-12-16 2012-07-25 北京握奇数据系统有限公司 Integrated circuit (IC) card reader-writer
CN104459418A (en) * 2014-12-27 2015-03-25 宁夏大学 IC card service life testing method and device
CN105120483A (en) * 2015-07-08 2015-12-02 惠州Tcl移动通信有限公司 Method and system for automatically testing compatibility between intelligent card and mobile terminal
CN105404574A (en) * 2015-12-10 2016-03-16 惠州Tcl移动通信有限公司 Method and apparatus for testing consistency of smart card and mobile terminal

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6913196B2 (en) * 2002-02-20 2005-07-05 O2Micro International Limited Dual mode controller for ISO7816 and USB enabled smart cards

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1553327A (en) * 2003-05-30 2004-12-08 上海华园微电子技术有限公司 Circuit for testing EEPROM and testing method thereof
CN101413986A (en) * 2007-10-17 2009-04-22 北京中电华大电子设计有限责任公司 Method for testing reliability of smart card
CN102567070A (en) * 2010-12-15 2012-07-11 沈阳新邮通信设备有限公司 Mobile phone software debugging method and simulator for mobile phone software
CN102521178A (en) * 2011-11-22 2012-06-27 北京遥测技术研究所 High-reliability embedded man-machine interface and realizing method thereof
CN102495797A (en) * 2011-11-25 2012-06-13 大唐微电子技术有限公司 Smart card testing device and method
CN102521197A (en) * 2011-12-13 2012-06-27 福建鑫诺通讯技术有限公司 Method for realizing ISO7816 protocol with UART (universal asynchronous receiver/transmitter) of low-cost MCU (micro-control unit)
CN202351905U (en) * 2011-12-16 2012-07-25 北京握奇数据系统有限公司 Integrated circuit (IC) card reader-writer
CN104459418A (en) * 2014-12-27 2015-03-25 宁夏大学 IC card service life testing method and device
CN105120483A (en) * 2015-07-08 2015-12-02 惠州Tcl移动通信有限公司 Method and system for automatically testing compatibility between intelligent card and mobile terminal
CN105404574A (en) * 2015-12-10 2016-03-16 惠州Tcl移动通信有限公司 Method and apparatus for testing consistency of smart card and mobile terminal

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
ByteArray类,实现Flash的ByteArray方法;dcboy;《https://blog.csdn.net/dcboy/article/details/5934043》;20101011;附件正文全文

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110568346A (en) * 2019-10-08 2019-12-13 东信和平科技股份有限公司 Aging test method and system for smart card

Also Published As

Publication number Publication date
CN106294181A (en) 2017-01-04

Similar Documents

Publication Publication Date Title
Liang et al. Caiipa: Automated large-scale mobile app testing through contextual fuzzing
CN105426298B (en) A kind of method for testing software and system based on ADB
US10341215B2 (en) Methods, systems, and computer readable media for emulating network traffic patterns on a virtual machine
CN103049363B (en) Verification method of NAND (neither agree not disagree) Flash controller
CN105094783A (en) Method and device for testing Android application stability
CN105912473A (en) BDD-based mobile APP automatic testing platform and testing method
CN104077204B (en) Reconfigurable 8 RSIC singlechip emulators
CN104268079A (en) POS (Point Of Sale) application program testing method and system
CN103927256A (en) Method for controlling multiple Android devices
CN109495293B (en) Method, system, equipment and storage medium for testing control surface of switch
CN106294181B (en) Smart card software service life test method
CN105653438A (en) Method and device for cross-process automated testing of Android device
CN110298007A (en) User behavior statistical method, device, electronic equipment and computer readable storage medium
CN104915297A (en) APP electricity consumption automatic test method for android device
CN115698941A (en) Efficient packaging of components
CN103746873A (en) System and method for testing communication module
CN105389200A (en) Multi-group stimulation batch simulation method and system applied to super-large scale chip verification
CN105550103A (en) Custom test script based automated testing method
CN105224453A (en) The automatic test approach of system compatibility and device
CN105824682B (en) A kind of monitoring method of virtual machine, device and system
CN115442266A (en) Gateway performance testing method and device, storage medium and electronic device
CN108804328A (en) Android application compatibility test method
CN108563460A (en) Plug-in-based android application new function release method
CN111124890B (en) Distributed database performance test method, system, terminal and storage medium
CN105242921A (en) Compatibile UI developing device and application therefor

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20190201

Termination date: 20200824

CF01 Termination of patent right due to non-payment of annual fee