Note: Forums will be making significant UX changes to address key usability improvements surrounding search, discoverability and navigation. To learn more about these changes please visit the announcement which can be found HERE.

Answered WinBio errors

  • Wednesday, June 27, 2012 6:55 AM
     
     

    Good day,

    I work on StorageAdapter for winBio framework and I am using WBF test suite for testing the functionality.

    I am having difficulties with error: "WbioStorageNextRecord should keep the last result when returning WINBIO_E_DATABASE_NO_MORE_RECORDS".

    I simply don't understand what does it want from me.  WbioStorageNextRecord should only advance result set. When it is at boundary I simply don't move it any further and result set is unchanged. The old result from "StorageAdapterGetCurrentRecord" is unchanged too and addresses should be still valid.  

    Thanks in advance


    • Edited by Jurysko Wednesday, June 27, 2012 11:23 AM
    •  

All Replies

  • Thursday, June 28, 2012 11:36 AM
     
     
    No one is even working with Windows Biometric framework ?
  • Thursday, June 28, 2012 4:46 PM
     
     Answered

    This particular test works as follows:

    1. It queries the database to get a non-empty result set
    2. It iterates through the result set until it hits the last record (hr == WINBIO_E_DATABASE_NO_MORE_RECORDS)
    3. It calls StorageAdapterGetCurrentRecord and captures the last record in a WINBIO_STORAGE_ITEM. Call this "record_1".
    4. Without modifying the result set, it repeatedly calls StorageAdapterNextRecord and StorageAdapterGetCurrentRecord, each time capturing the record contents in a different WINBIO_STORE_ITEM. Call this "record_2".
    5. After the iteration cycle, it compares the contents of record_1 and record_2. If they are not equal, the test fails with the error message you're seeing.

    "Equality" in this case means:

    • Same identity (SID or GUID)
    • Same subfactor value
    • Same index element count
    • If index element count is non-zero, then the index element arrays must be the same.
    • The template blob sizes must be identical, and the byte-by-byte contents of the blobs must be identical.
    • The payload blob sizes must match, and if the blob size is non-zero, the pay blobs must be identical on a byte-by-byte basis.

    If any of these conditions don't match, the test fails and generates the error you're seeing.

    Does that help?

    Regards,
    -Art Baker
    Senior Software Engineer - Windows Security
    www.microsoft.com/security

  • Thursday, June 28, 2012 5:09 PM
     
     

    Thanks for the reply! I thought no one deals with WBF.

    In debug mode i watched the whole structure which I am returning (beside debug printfs) and it seems all right. NextRecord returns specified error and getRecord returns the last record as it should at every call.

    The Identity structure,IndexVector,TemplateBlob and PayloadBlob are still the same - they are allocated via  "new" operator. So I put still the same pointers to these structures and fill static data (SubFactor, sizes, etc.) to "PWINBIO_STORAGE_RECORD RecordContents".

    So one possibility for me is to store these let's say 6 records of repeated calls to "StorageAdapterNextRecord" and "StorageAdapterGetCurrentRecord" to a file and compare the content whether it matches in mentioned points.

    I'll try that as soon as I can.

    Thanks again

  • Monday, July 02, 2012 8:49 AM
     
     
    It seems that I overlooked stupid error. I forgot to set SubFactor of the record. That's why it never matched the template.
  • Monday, July 02, 2012 1:16 PM
     
     

    I'd like to ask something else. .dll adapters are installed with device drivers. How to use my own implementation of dll adapter (storage).  What do I need for it? OpenSession shouts that integrity check failed after I replace storage adapter with my own.

    Thanks in advance


    • Edited by Jurysko Monday, July 09, 2012 9:46 AM
    •  
  • Monday, July 09, 2012 11:30 AM
     
     

    If I can ask something else what exactly is test 5 (create database) doing? From debug output everything seems to be all right but it says "Database file can't be found". Is the testing suite looking for the file in file system? Or something else. Btw almost all the test are functioning properly except 7 that shouts mentioned statement.

    Thanks in advance.