ESYAE-imza Kütüphaneleri

User Tools

Site Tools


en:esya:smartcard:konfig

Farklar

Bu sayfanın seçili sürümü ile mevcut sürümü arasındaki farkları gösterir.

Karşılaştırma görünümüne bağlantı

en:esya:smartcard:konfig [2013/09/12 07:50]
Dindar Öz oluşturuldu
en:esya:smartcard:konfig [2013/09/12 08:13] (mevcut)
Dindar Öz
Satır 1: Satır 1:
 ===== Configuration ===== ===== Configuration =====
  
-Akıllı kart kütüphanesinde konfigürasyon aracılığı ile  +ESYA Smartcard API uses configuration file in order to 
-                - Yeni kart tipi tanımlanabilir +                - define a new card type 
-                - Kart driver ​değiştirilebilir +                - specify a card driver 
-                - Tanımlı kart tiplerine, kartı tanımaya yarayan yeni ATR değerleri eklenebilir.Böylece sistemde yeni bir kart(marka/​versiyon) ​ kullanılabilir.+                - add new ATR values to existing card types, which are used to detect card.
  
-Bu işlemler API ile birlikte dağıtılan ​''​smartcard-config.xml'' ​adındaki konfigürasyon dosyası ile yapılmaktadır. Bu dosyada ilk değerler vardırBu değerler ​API içinde gömülü olduğu içinyeni bir ayar yapılmayacaksa bu dosyayı kullanmaya gerek yoktur+The configuration file is ''​smartcard-config.xml'' ​and distributed within the API packageInitial values are set in this file and these initial values are also embedded in the API source. If no new card configuration existsthen there is no need to use the configuration file.
  
-Eğer konfigürasyonda değişiklik yapılırsakonfigürasyon dosyası ​''​SmartCardConfigParser'' ​aracılığı ile okunmalı ve ''​CardType'' ​sınıfı, bu konfigürasyondan haberdar edilmelidir.+If the configuration file is modifiedthen it must be read via ''​SmartCardConfigParser'' ​and the class ''​CardType'' ​must be configured accordingly
  
-Örnek KodÇalışma dizini içindeki ​''​smartcard-config.xml'' ​ile akıllı kart konfigürasyonu yapma.+Sample CodeUsing the configuration file ''​smartcard-config.xml''​ .
 <sxh java> <sxh java>
         List<​CardTypeConfig>​ cards = new SmartCardConfigParser().readConfig();​         List<​CardTypeConfig>​ cards = new SmartCardConfigParser().readConfig();​
Satır 16: Satır 16:
 </​sxh>​ </​sxh>​
  
-Eğer konfigürasyon dosyası farklı bir isimde ya da başka bir lokasyonda ise ''​SmartCardConfigParser'' ​sınıfının InputStream nesnesi alan metodu da kullanılabilir:​+If the configuration file has different name or it is at some other location then  the method which is taking ''​InputStream''​ of ''​SmartCardConfigParser'' ​can be used. 
 <sxh java> <sxh java>
         List<​CardTypeConfig>​ cards = new SmartCardConfigParser().readConfig(inputStream);​         List<​CardTypeConfig>​ cards = new SmartCardConfigParser().readConfig(inputStream);​
Satır 22: Satır 23:
 </​sxh>​ </​sxh>​
  
-==== Konfigürasyon ile Kart Tipi Tanımlama ​====+==== Defining a New Card Type  ​====
  
-Aşağıda örnek bir akıllı kart tanımlaması görülmektedir:+sample card definition is as follows:
 <sxh xml> <sxh xml>
 <​card-type name="​AKIS">​ <​card-type name="​AKIS">​
Satır 34: Satır 35:
 </​sxh>​ </​sxh>​
  
-''<​card-type>'' ​elemanı ile kart tipi tanımlanır. ''<​lib>'' ​elemanı işletim sistemine özel driver ​belirtmek için kullanılır. +''<​card-type>'' ​defines the new card type. ''<​lib>'' ​specifies the operationg system specific ​driver ​of the cardIf 32 bit and 64 bit platforms requires different ​driver ​this seperation is indicated as follows:
-Eğer 32 ve 64 bit mimariler için farklı ​driver ​gerekiyorsa bu ayrım ''​arch''​ özelliği ile aşağıdaki gibi belirtilir.+
 <sxh xml> <sxh xml>
     <​card-type name="​NCIPHER">​     <​card-type name="​NCIPHER">​
Satır 44: Satır 44:
 ==== ATR Değeri ==== ==== ATR Değeri ====
  
-Kart tipini anlamak için karta özel ATR değerini bilmek gerekmektedir. ATR, Answer To Reset ifadesinin kısaltmasıdırProtokol gereği kart resetlendiğinde tanıtıcı bir byte dizisi gönderir Eğer bu byte dizisi biliniyorsa,​ ve karta özel ayırdedici bilgi içeriyorsa(historical bytes) kart tipi tespit edilebilirBilinen her bir ATR byte dizisi için ''<​card-type>'' ​elemanı içine yukarıdaki örnekteki gibi bir ''<​atr>'' ​elemanı eklenmelidir.+To detect the card type you need to know the ATR (Answer To Reset) value of the cardAs defined in the communication protocol of the card, it sends out a byte sequence when it is resetIf this byte sequence is known and it includes a unique information for a specific card then the card type is detected For all known ATR sequences there must be an ''<​atr>'' ​element in ''<​card-type>'' ​in the configuration file.
  
-Java ile ATR değeri hesaplamak için aşağıdaki kod parçasını kullanabilirsinizKod ilk terminaldeki(kart okuyucu) akıllı kartın ATRsini ekrana yazdırmaktadır.+To retrieve ​ATR value from card with Java, you can use the code segment belowThe code simply prints out the ATR of the smartcard in the first reader.
 <sxh java;​title:​Java>​ <sxh java;​title:​Java>​
 Card card = TerminalFactory.getDefault().terminals().list().get(0).connect("​*"​);​ Card card = TerminalFactory.getDefault().terminals().list().get(0).connect("​*"​);​
Satır 55: Satır 55:
 System.out.println("​ATR >"​+atrHex);​ System.out.println("​ATR >"​+atrHex);​
 </​sxh>​ </​sxh>​
- 
en/esya/smartcard/konfig.1378972229.txt.gz · Son değiştirilme: 2013/09/12 07:50 Değiştiren: Dindar Öz