简体   繁体   中英

Create an applet to change LifeCycle of the card or other applets

Is it possible to write an applet that it has ability and privelege to change life cycle of the card or life cycle of the other applets? If so, how? Which classes and methods I must use?

Yes it is possible to write an applet which can change the life cycle of CARD as well as other applications, for this this some appropriate methods should be used. But this applet need some privileges. Any ordinary application can't do this, only privilege application can do this.

  • Global Platform provide an interface GPRegistryEntry , you need to implement following method of this interface to change the life cycle of another application :

public boolean setState(byte bState)

: This method allows the Life Cycle state of this GPRegistryEntry to be transitioned to the requested target state.

  • Global Platform also provide a class GPSystem wich provide following methods :

public static boolean setCardContentState(byte bState)

:This method sets the Application specific Life Cycle State of the current applet context.

public static boolean lockCard()

: This method locks the card.

public static boolean terminateCard()

: This method terminates the card.

Hope this will help you.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM