os/security/contentmgmt/cafstreamingsupport/test/tscaf/scripts/tscaf.script
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 //
     2 // Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
     3 // All rights reserved.
     4 // This component and the accompanying materials are made available
     5 // under the terms of the License "Eclipse Public License v1.0"
     6 // which accompanies this distribution, and is available
     7 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     8 //
     9 // Initial Contributors:
    10 // Nokia Corporation - initial contribution.
    11 //
    12 // Contributors:
    13 //
    14 // Description:
    15 //
    16 // Streaming CAF Integration Tests
    17 
    18 PRINT Run PREQ782 Streaming CAF Integration Tests
    19 
    20 // Load Suite
    21 LOAD_SUITE tscaf
    22 
    23 
    24 //! @SYMTestCaseID 		SEC-SCAF-MISC-0001
    25 //! @SYMTestCaseDesc 		StartupComms
    26 
    27 START_TESTCASE SEC-SCAF-MISC-0001
    28 RUN_TEST_STEP 100 tscaf StartupCommsStep
    29 END_TESTCASE SEC-SCAF-MISC-0001
    30 
    31 
    32 //********************** SEC-SCAF-A : CONSUMER INTERFACE  **********************
    33 
    34 //! @SYMTestCaseID 		SEC-SCAF-A001
    35 //! @SYMTestCaseDesc 		Key stream decoder construction with a supported protected key stream description
    36 //! 				(keystreamdecoder_positiveconstruct)
    37 //! @SYMPREQ 			PREQ782
    38 //! @SYMREQ 			REQ7772, REQ7776, REQ7781, REQ7784, REQ7954
    39 //! @SYMTestPriority 		Critical
    40 //! @SYMTestStatus   		Implemented
    41 //! @SYMTestActions 		Preconditions:
    42 //!				• There are the necessary ROM based test stream agent plug-ins present that support 
    43 //!				the SDP media description supplied during construction of the key stream decoder.
    44 //!
    45 //!				Test Actions:
    46 //!				• Generate a protected key stream description.
    47 //!				• Generate an SDP media description for the key stream.
    48 //!				• Construct the key stream decoder using the protected stream description and SDP
    49 //!				media description objects previously generated.
    50 //!				• Destroy the key stream decoder object.
    51 //!
    52 //! @SYMTestExpectedResults 	• The key stream decoder is successfully created and destroyed.
    53 //! @SYMTestType 		CIT
    54 
    55 START_TESTCASE SEC-SCAF-A001
    56 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Program
    57 RUN_TEST_STEP 100 tscaf SCAFKeyStreamDecoderConstruct z:\tcaf\tscaf\tscaf.ini keystreamdecoder_positiveconstruct
    58 END_TESTCASE SEC-SCAF-A001
    59 
    60 
    61 
    62 //! @SYMTestCaseID 		SEC-SCAF-A002
    63 //! @SYMTestCaseDesc 		Key stream decoder construction with an unsupported protected key stream description
    64 //! 				(keystreamdecoder_negativeconstruct)
    65 //! @SYMPREQ 			PREQ782
    66 //! @SYMREQ 			REQ7772, REQ7776, REQ7781, REQ7784, REQ7954
    67 //! @SYMTestPriority 		Critical
    68 //! @SYMTestStatus   		Implemented
    69 //! @SYMTestActions  		Preconditions:
    70 //!				• The ROM based test stream agent plug-ins present DO NOT support the SDP media 
    71 //!				description supplied during construction of the key stream decoder.
    72 //!			
    73 //!				Test Actions:
    74 //!				• Generate a protected key stream description.
    75 //!				• Generate an SDP media description for the key stream that is incompatible with all
    76 //!				available stream agent implementations.
    77 //!				• Construct the key stream decoder using the protected stream description and 
    78 //!				incompatible SDP media description objects previously generated.			
    79 //! @SYMTestExpectedResults 	• Construction of the key stream decoder leaves with the KErrCANoAgent error code.
    80 //! @SYMTestType 		CIT
    81 
    82 START_TESTCASE SEC-SCAF-A002
    83 RUN_TEST_STEP !Result=-17453 100 tscaf SCAFKeyStreamDecoderConstruct z:\tcaf\tscaf\tscaf.ini keystreamdecoder_negativeconstruct
    84 END_TESTCASE SEC-SCAF-A002
    85 
    86 
    87 
    88 //! @SYMTestCaseID 		SEC-SCAF-A004
    89 //! @SYMTestCaseDesc 		Querying attributes related to a key stream decoder
    90 //! 				(keystreamdecoder_positivequery)
    91 //! @SYMPREQ 			PREQ782
    92 //! @SYMREQ 			REQ7772, REQ7776, REQ7784, REQ7954
    93 //! @SYMTestPriority 		Critical
    94 //! @SYMTestStatus   		Implemented
    95 //! @SYMTestActions  		Preconditions:
    96 //!				• The necessary ROM based test stream agent plug-in is present that supports the SDP
    97 //!				media description 	
    98 //!				supplied during construction of the key stream decoder.
    99 //!				• There are two Rights Objects files (serviceProtectedRO and programProtectedRO) in
   100 //!				the private folder of the supporting test stream agent.
   101 //!				• The Rights Issuer URI of the serviceProtectedRO is set to “IssuerUriServiceProtectedRO”
   102 //!				and programProtectedRO is set to “IssuerUriProgramProtectedRO”
   103 //!			
   104 //!				Test Actions:
   105 //!				• Generate a protected key stream description.
   106 //!				• Generate an SDP media description for the key stream with an attribute requiring 
   107 //!				programProtectedRO
   108 //!				• Construct the key stream decoder using the protected stream description and SDP media 
   109 //!				description objects previously generated.
   110 //!				• Query the stream agent to determine whether the program is protected.
   111 //!				• Query the stream agent to determine whether the whole service is protected.
   112 //!				• Query the stream agent to retrieve the Rights Issuer URI.
   113 //!				• Destroy the key stream decoder object.
   114 //!				
   115 //! @SYMTestExpectedResults 	• The key stream decoder is successfully created.
   116 //!				• The program is protected but the whole service is not.
   117 //!				• The Rights Issuer URI retrieved is “IssuerUriProgramProtectedRO”
   118 //!
   119 //! @SYMTestType 		CIT
   120 
   121 START_TESTCASE SEC-SCAF-A004
   122 
   123 // Copy the necessary 'Program' Protected rights objects into the stream agent's private directory
   124 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Program
   125 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_positivequery_programprotectedRO
   126 
   127 // Copy the necessary 'Service' Protected rights objects into the stream agent's private directory
   128 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Service
   129 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_positivequery_serviceprotectedRO
   130 
   131 END_TESTCASE SEC-SCAF-A004
   132 
   133 
   134 
   135 //! @SYMTestCaseID 		SEC-SCAF-A005
   136 //! @SYMTestCaseDesc 		Querying attributes related to a key stream decoder with missing rights object
   137 //! 				(keystreamdecoder_missingrights)
   138 //! @SYMPREQ 			PREQ782
   139 //! @SYMREQ 			REQ7772, REQ7776, REQ7784, REQ7954
   140 //! @SYMTestPriority 		Critical
   141 //! @SYMTestStatus   		Implemented
   142 //! @SYMTestActions  		Preconditions:
   143 //!				• The necessary ROM based test stream agent plug-in is present that supports the SDP 
   144 //!				media description supplied during construction of the key stream decoder.
   145 //!				• The program protected rights object (programProtectedRO) exists in the private 
   146 //!				directory of the supporting test stream agent, but the service protected rights object 
   147 //!				(serviceProtectedRO) is missing.
   148 //!			
   149 //!				Test Actions:
   150 //!				• Generate a protected key stream description.
   151 //!				• Generate an SDP media description for the key stream with an attribute requiring 
   152 //!				serviceProtectedRO.
   153 //!				• Construct the key stream decoder using the protected stream description and SDP media 
   154 //!				description objects previously generated.
   155 //!				• Query the stream agent to determine whether the program is protected.
   156 //!				• Destroy the key stream decoder object.
   157 //!
   158 //! @SYMTestExpectedResults 	• Querying the stream agent results in a leave with error code KErrCANoRights, showing 
   159 //!				that serviceProtectedRO is missing.
   160 //!
   161 //! @SYMTestType 		CIT
   162 
   163 START_TESTCASE SEC-SCAF-A005
   164 
   165 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_None
   166 
   167 RUN_TEST_STEP !Result=-17452 tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_missingrights
   168 
   169 END_TESTCASE SEC-SCAF-A005
   170 
   171 
   172 
   173 //! @SYMTestCaseID 		SEC-SCAF-A006
   174 //! @SYMTestCaseDesc 		Querying attributes related to a key stream decoder with an expired rights object
   175 //! 				(keystreamdecoder_expiredrights)
   176 //! @SYMPREQ 			PREQ782
   177 //! @SYMREQ 			REQ7772, REQ7776, REQ7784, REQ7954
   178 //! @SYMTestPriority 		Critical
   179 //! @SYMTestStatus   		Implemented
   180 //! @SYMTestActions  		Preconditions:
   181 //!				• The necessary ROM based test stream agent plug-in is present that supports the SDP media
   182 //!				description supplied during construction of the key stream decoder.
   183 //!				• There is an expired Rights Object file (expiredRO) in the private folder of the supporting 
   184 //!				test stream agent.
   185 //!			
   186 //!				Test Actions:
   187 //!				• Generate a protected key stream description.
   188 //!				• Generate an SDP media description for the key stream with an attribute requiring expiredRo.
   189 //!				• Construct the key stream decoder using the protected stream description and SDP media 
   190 //!				description objects previously generated.
   191 //!				• Query the stream agent to determine whether the program is protected.
   192 //!				• Destroy the key stream decoder object.
   193 //!
   194 //! @SYMTestExpectedResults 	• Querying the stream agent results in a leave with error code KErrCANoPermission, showing
   195 //!				that expiredRo has expired.
   196 //!
   197 //! @SYMTestType 		CIT
   198 
   199 START_TESTCASE SEC-SCAF-A006
   200 
   201 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Expired
   202 
   203 RUN_TEST_STEP !Result=-17451 tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_expiredrights
   204 
   205 END_TESTCASE SEC-SCAF-A006
   206 
   207 
   208 
   209 //! @SYMTestCaseID 		SEC-SCAF-A007
   210 //! @SYMTestCaseDesc 		Concurrent key stream decoder construction and querying
   211 //! 				(keystreamdecoder_concurrentquery)
   212 //! @SYMPREQ 			PREQ782
   213 //! @SYMREQ 			REQ7772, REQ7776, REQ7781, REQ7784, REQ7954
   214 //! @SYMTestPriority 		Critical
   215 //! @SYMTestStatus   		Implemented
   216 //! @SYMTestActions  		Preconditions:
   217 //!				The following test actions should be carried out concurrently in 3 separate threads:
   218 //!				• Generate a protected key stream description.
   219 //!				• Generate an SDP media description. Thread A should generate an SDP media description
   220 //!				supported by test stream agent plug-in A and Threads B & C should generate SDP media
   221 //!				description objects supported by test stream agent plug-in B.
   222 //!				• Construct a key stream decoder object using the generated protected key stream
   223 //!				description and SDP media description objects.
   224 //!				• When the key stream decoder has been constructed, query the attributes associated
   225 //!				with the stream agent.
   226 //!				• Destroy the key stream decoder object.
   227 //!
   228 //! @SYMTestExpectedResults 	• Each key stream decoder object should construct successfully.
   229 //!				• Checking the implementation attributes reveals that Thread A has invoked test stream
   230 //!				agent A and Thread B & C have invoked test stream agent B.
   231 //!
   232 //! @SYMTestType 		CIT
   233 
   234 START_TESTCASE SEC-SCAF-A007
   235 
   236 // Copy the necessary rights objects into the stream agent's private directory
   237 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_ServiceProgram
   238 
   239 CONCURRENT
   240 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_concurrentquery_threadA
   241 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_concurrentquery_threadB
   242 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini keystreamdecoder_concurrentquery_threadC
   243 CONSECUTIVE
   244 
   245 END_TESTCASE SEC-SCAF-A007
   246 
   247 
   248 
   249 //! @SYMTestCaseID 		SEC-SCAF-A008
   250 //! @SYMTestCaseDesc 		Concurrent multi-thread usage of multiple key stream decoders
   251 //! 				(multikeystreamdecoders)
   252 //! @SYMPREQ 			PREQ782
   253 //! @SYMREQ 			REQ7772, REQ7775, REQ7776, REQ7781, REQ7784, REQ7954
   254 //! @SYMTestPriority 		Critical
   255 //! @SYMTestStatus   		Implemented
   256 //! @SYMTestActions  		Preconditions:
   257 //!				The following test actions should be carried out concurrently in 3 separate threads:
   258 //!				• Generate a protected key stream description.
   259 //!				• Generate an SDP media description (SDPa) for the key stream with an attribute
   260 //!				requiring serviceProtectedRO.
   261 //!				• Construct a key stream decoder object using the generated protected key stream
   262 //!				description and SDP media description object SDPa – decoderA.
   263 //!				• Generate another SDP media description (SDPb) for the key stream with an attribute
   264 //!				requiring programProtectedRO.
   265 //!				• Construct another key stream decoder object using the generated protected key stream
   266 //!				description and SDP media description object SDPb – decoderB.
   267 //!				• Query decoderA to retrieve the ‘Rights Issuer URI’ attribute from the invoked 
   268 //!				stream agent.
   269 //!				• Query decoderB to retrieve the ‘Rights Issuer URI’ attribute from the invoked 
   270 //!				stream agent.
   271 //!				• Destroy both key stream decoder objects.			
   272 //!
   273 //! @SYMTestExpectedResults 	• Each key stream decoder object should construct successfully.
   274 //!				• The Rights Issuer URI  attribute value retrieved from decoderA is 
   275 //!				“IssuerUriServiceProtectedRO”
   276 //!				• The Rights Issuer URI  attribute value retrieved from decoderB is 
   277 //!				“IssuerUriProgramProtectedRO”
   278 //!
   279 //! @SYMTestType 		CIT
   280 
   281 START_TESTCASE SEC-SCAF-A008
   282 
   283 // Copy the necessary rights objects into the stream agent's private directory
   284 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_ServiceProgram
   285 
   286 // 2 Key Stream Decoders, Invoking the same stream agent
   287 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_singlethread_singleagent
   288 
   289 // 2 Key Stream Decoders, Invoking different stream agents
   290 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_singlethread_multiagents
   291 
   292 // 3 concurrent threads, 2 key stream decoders per thread invoking the same agent
   293 CONCURRENT
   294 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_singleagent_threadA
   295 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_singleagent_threadB
   296 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_singleagent_threadC
   297 CONSECUTIVE
   298 
   299 // 3 concurrent threads, 2 key stream decoders per thread invoking different agents 
   300 CONCURRENT
   301 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_multiagents_threadA
   302 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_multiagents_threadB
   303 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_multiagents_threadC
   304 CONSECUTIVE
   305 
   306 END_TESTCASE SEC-SCAF-A008
   307 
   308 
   309 
   310 //******************	TEST STREAM AGENT UNIT TESTING	    *******************
   311 
   312 //! @SYMTestCaseID SEC-SCAF-S001
   313 //! @SYMTestCaseDesc A unit test step which tests the Test Streaming Agent
   314 //! 		     (StreamingTestAgent)
   315 //! @SYMREQ Req-b
   316 //! @SYMTestPriority Low
   317 //! @SYMTestActions A connection is established with the Test Agent Server via its client side and the closed.  
   318 //! @SYMTestExpectedResults Successful connection and disconnectiom to/from the Test Streaming Agent Server. 
   319 //! @SYMDevelopedForRelease Oghma
   320 
   321 START_TESTCASE SEC-SCAF-S001
   322 RUN_TEST_STEP 100 tscaf SCAFTestAgentServer
   323 END_TESTCASE SEC-SCAF-S001
   324 
   325 
   326 
   327 //************	SEC-SCAF-C : INTEROPERABILITY WITH DECODING STACK   ***********
   328 
   329 
   330 //! @SYMTestCaseID 		SEC-SCAF-C001
   331 //! @SYMTestCaseDesc 		Usage of key stream sink
   332 //! 				(keystreamsinks)
   333 //! @SYMPREQ 			PREQ782
   334 //! @SYMREQ 			REQ7774, REQ7778, REQ7786
   335 //! @SYMTestPriority 		Critical
   336 //! @SYMTestStatus   		Implemented
   337 //! @SYMTestActions  		Preconditions:
   338 //!				• There are the necessary ROM based test stream agent plug-ins present that support 
   339 //!				the SDP media description supplied during construction of each key stream decoder.
   340 //!				• There is a Right Object file in the private folder of the supporting test stream agent.
   341 //!
   342 //!				Test Actions:
   343 //!				• Create a key stream sink
   344 //!				• Create a plain key and encrypt it with the key extracted from the RO
   345 //!				• Connect to the Test Agent
   346 //!				• Send the key stream sink
   347 //!				• Send the encrypted string (a simple key stream)
   348 //!				• The test agent server decrypts the key stream by using the key from the RO.
   349 //!				• The test agent server processes the decrypted key (the key is written into a file 
   350 //!				defined in the key stream sink)
   351 //!				• Check whether the right plain key is written down 
   352 //!				• Destroy the key stream decoder object.				
   353 //!
   354 //! @SYMTestExpectedResults 	• The plain string is found in the predefined location.
   355 //!
   356 //! @SYMTestType 		CIT
   357 
   358 START_TESTCASE SEC-SCAF-C001
   359 RUN_TEST_STEP 100 tscaf SCAFKeyStreamSink z:\tcaf\tscaf\tscaf.ini sdp_service_protected
   360 END_TESTCASE SEC-SCAF-C001
   361 
   362 
   363 
   364 //! @SYMTestCaseID 		SEC-SCAF-C002
   365 //! @SYMTestCaseDesc 		Usage of key stream sinks in concurrent sessions
   366 //! 				(concurrent_keystreamsinks)
   367 //! @SYMPREQ 			PREQ782
   368 //! @SYMREQ 			REQ7774, REQ7778, REQ7786
   369 //! @SYMTestPriority 		Critical
   370 //! @SYMTestStatus   		Preconditions:
   371 //!				• There are the necessary ROM based test stream agent plug-ins present that support
   372 //!				the SDP media description supplied during construction of each key stream decoder.
   373 //!				• There are two Rights Object files (serviceProtectedRO and programProtectedRO) in the
   374 //!				private folder of each test stream agent.
   375 //!
   376 //!				Test Actions:
   377 //!				• Generate a protected key stream description.
   378 //!				• Generate an SDP media description (SDPa) for the key stream with an attribute requiring
   379 //!				serviceProtectedRO.
   380 //!				• Construct a key stream decoder object using the generated protected key stream 
   381 //!				description and SDP media description object SDPa – decoderA.
   382 //!				• Generate another SDP media description (SDPb) for the key stream with an attribute requiring 
   383 //!				programProtectedRO.
   384 //!				• Construct another key stream decoder object using the generated protected key stream 
   385 //!				description and SDP media description object SDPb – decoderB.
   386 //!				• Create plain_keyA
   387 //!				• Encrypt plain_keyA with encryption_keyA extracted from serviceProtectedRO
   388 //!				• Send the encrypted plain_keyA using decoderA
   389 //!				• Create plain_keyB
   390 //!				• Encrypt plain_keyB with encryption_keyB extracted from programProtectedRO
   391 //!				• Send the encrypted plain_keyB using decoderB
   392 //!				• Check whether stringA is in pathA and stringB is in pathB
   393 //!				• Destroy both key stream decoder objects.				
   394 //!
   395 //! @SYMTestExpectedResults 	• The plain strings are found in the predefined locations.
   396 //!
   397 //! @SYMTestType 		CIT
   398 
   399 START_TESTCASE SEC-SCAF-C002
   400 RUN_TEST_STEP 100 tscaf SCAFConcurrentKeyStreamSinks z:\tcaf\tscaf\tscaf.ini concurrent_keystreamsinks
   401 END_TESTCASE SEC-SCAF-C002
   402 
   403 
   404 
   405 //********************** SEC-SCAF-D : POST-ACQUISITION  **********************
   406 
   407 
   408 //! @SYMTestCaseID 		SEC-SCAF-D001
   409 //! @SYMTestCaseDesc 		Post-acquisition content protection
   410 //! 				(postacqusition)
   411 //! @SYMPREQ 			PREQ782
   412 //! @SYMREQ 			REQ7788
   413 //! @SYMTestPriority 		Critical
   414 //! @SYMTestStatus   		Implemented
   415 //! @SYMTestActions  		Preconditions:
   416 //!				The following test actions should be carried out:
   417 //!				• Copy  rorecordable.dr (a rights object where ECanExport and EMustProtectIfRecording
   418 //!				flags shall be set) and its post-acquistion rights object (ropostacquisition.dr) into
   419 //!				the private directory of the test agent server.
   420 //!			      	• Generate a test key stream description
   421 //!				• Generate an SDP media description for the key stream with an attribute requiring 
   422 //!				rorecordable.dr
   423 //!				• Construct the key stream decoder using the protected key stream description and SDP
   424 //!				media description objects previously generated.
   425 //!				• Query the stream agent to determine whether it is allowed to export and record the 
   426 //!				content.
   427 //!				• Request and gets a handle to the postacqusition rights object file
   428 //!				• Import the postacqusition rights object file to the post-acquisition caf agent
   429 //!                     	• Open a session to import the content
   430 //!				• Import the content to the post-acquisition caf agent	
   431 //!
   432 //! @SYMTestExpectedResults 	
   433 //!				• The protected stream is allowed to be recorded
   434 //!				• The test streaming agent returns a handle of the post-acquistion RO successfully
   435 //!				• The post-acquistion RO is successfully imported to the post-acquisition caf agent
   436 //!
   437 //! @SYMTestType 		CIT
   438 
   439 START_TESTCASE SEC-SCAF-D001
   440 
   441 RUN_TEST_STEP 100 tscaf SCAFPostAcquisition z:\tcaf\tscaf\tscaf.ini post_acquisition
   442 
   443 RUN_TEST_STEP 100 tscaf SCAFPostAcquisition z:\tcaf\tscaf\tscaf.ini post_acquisition_create_outputs
   444 
   445 END_TESTCASE SEC-SCAF-D001
   446 
   447 
   448 
   449 //********************** SEC-SCAF-E : INTEROPERABILITY WITH DECODING STACK - IPSEC    ***********
   450 
   451 RUN_SCRIPT z:\tcaf\tscaf\tscafipsec.script
   452 
   453 
   454 
   455 //********************** SEC-SCAF-G : SINGLE PROCESS STREAM AGENT TESTING  **********************
   456 
   457 //! @SYMTestCaseID 		SEC-SCAF-G001
   458 //! @SYMTestCaseDesc 		SPSA - Key stream decoder construction with a supported protected key stream description
   459 //! 				(spsa_keystreamdecoder_positiveconstruct)
   460 //! @SYMPREQ 			PREQ782
   461 //! @SYMREQ 			
   462 //! @SYMTestPriority 		High
   463 //! @SYMTestStatus   		Implemented
   464 //! @SYMTestActions  		Preconditions:
   465 //!				• The necessary ROM based ‘single process’ stream agent plug-in is present that supports
   466 //!				the SDP media description supplied during construction of the key stream decoder.
   467 //!
   468 //!				Test Actions:
   469 //!				• Run the test step actions as described in test case SEC-SCAF-A001.
   470 //!
   471 //! @SYMTestExpectedResults 	• The key stream decoder constructed by the single process stream agent is successfully 
   472 //!				created and destroyed.
   473 //!
   474 //! @SYMTestType 		CIT
   475 
   476 START_TESTCASE SEC-SCAF-G001
   477 RUN_TEST_STEP 100 tscaf SCAFKeyStreamDecoderConstruct z:\tcaf\tscaf\tscaf.ini spsa_keystreamdecoder_positiveconstruct
   478 END_TESTCASE SEC-SCAF-G001
   479 
   480 
   481 
   482 //! @SYMTestCaseID 		SEC-SCAF-G002
   483 //! @SYMTestCaseDesc 		SPSA - Querying attributes related to a key stream decoder
   484 //! 				(spsa_keystreamdecoder_positivequery)
   485 //! @SYMPREQ 			PREQ782
   486 //! @SYMREQ 			
   487 //! @SYMTestPriority 		High
   488 //! @SYMTestStatus   		Implemented
   489 //! @SYMTestActions  		Preconditions:
   490 //!				• The necessary ROM based ‘single process’ stream agent plug-in is present that supports
   491 //!				the SDP media description supplied during construction of the key stream decoder.
   492 //!				• The required Rights Object file is present in the private folder for the supporting 
   493 //!				single process stream agent.
   494 //!
   495 //!				Test Actions:
   496 //!				• Run the test step actions as described in test case SEC-SCAF-A004.				
   497 //!
   498 //! @SYMTestExpectedResults 	• The key stream decoder constructed by the single process stream agent is successfully
   499 //!				created.
   500 //!				• All of the expected attribute values match their corresponding values retrieved from
   501 //!				the key stream decoder.
   502 //!
   503 //! @SYMTestType 		CIT
   504 
   505 START_TESTCASE SEC-SCAF-G002
   506 
   507 // Copy the necessary 'Program' Protected rights objects into the single process stream agent's private directory
   508 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Program_SingleProcessAgent
   509 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini spsa_keystreamdecoder_positivequery_programprotectedRO
   510 
   511 // Copy the necessary 'Service' Protected rights objects into the single process stream agent's private directory
   512 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Service_SingleProcessAgent
   513 RUN_TEST_STEP tscaf SCAFKeyStreamDecoderAttributes z:\tcaf\tscaf\tscaf.ini spsa_keystreamdecoder_positivequery_serviceprotectedRO
   514 
   515 END_TESTCASE SEC-SCAF-G002
   516 
   517 
   518 
   519 //! @SYMTestCaseID 		SEC-SCAF-G003
   520 //! @SYMTestCaseDesc 		SPSA - Concurrent multi-thread usage of multiple key stream decoders
   521 //! 				(spsa_multikeystreamdecoders)
   522 //! @SYMPREQ 			PREQ782
   523 //! @SYMREQ 			
   524 //! @SYMTestPriority 		High
   525 //! @SYMTestStatus   		Implemented
   526 //! @SYMTestActions  		Preconditions:
   527 //!				• The necessary ROM based ‘single process’ and ‘client-server’ stream agent plug-in
   528 //!				implementations are present that support the SDP media descriptions supplied during 
   529 //!				construction of the key stream decoders.
   530 //!				• The required Rights Object files are present in the private folder of the supporting
   531 //!				stream agents.
   532 //!
   533 //!				Test Actions:
   534 //!				The following test actions should be carried out concurrently in 3 separate threads 
   535 //!				(1 of the threads should instantiate a ‘single process’ stream agent, whereas the others
   536 //!				should instantiate ‘client-server’ based stream agents) :
   537 //!				
   538 //!				• Run the test step actions as described in test case SEC-SCAF-A008 				
   539 //!
   540 //! @SYMTestExpectedResults 	• Each of the key stream decoder objects that have been constructed by either a 
   541 //!				client-server or single process stream agent plug-in are created successfully.
   542 //!				• All of the expected attribute values match their corresponding values retrieved from
   543 //!				the associated key stream decoder.
   544 //!
   545 //! @SYMTestType 		CIT
   546 
   547 START_TESTCASE SEC-SCAF-G003
   548 
   549 // Copy the necessary rights objects into the stream agent's private directory (Client/Server Architecture)
   550 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_ServiceProgram
   551 
   552 // Copy the necessary rights objects into the stream agent's private directory (Single Process Stream Agent)
   553 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_ServiceProgram_SingleProcessAgent
   554 
   555 // 2 Key Stream Decoders, Invoking the same single process stream agent
   556 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_singlethread_singleagent
   557 
   558 // 2 Key Stream Decoders, Invoking different stream agents (1 Single Process & 1 Client/Server)
   559 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_singlethread_multiagents
   560 
   561 // 3 concurrent threads, 2 key stream decoders per thread invoking the same agent
   562 CONCURRENT
   563 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_concurrent_singleagent_threadA
   564 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_singleagent_threadB
   565 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini multikeystreamdecoders_concurrent_singleagent_threadC
   566 CONSECUTIVE
   567 
   568 // 3 concurrent threads, 2 key stream decoders per thread invoking different agents (1 Single Process & 1 Client/Server)
   569 CONCURRENT
   570 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_concurrent_multiagents_threadA
   571 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_concurrent_multiagents_threadB
   572 RUN_TEST_STEP tscaf SCAFMultiKeyStreamDecoders z:\tcaf\tscaf\tscaf.ini spsa_multikeystreamdecoders_concurrent_multiagents_threadC
   573 CONSECUTIVE
   574 
   575 END_TESTCASE SEC-SCAF-G003
   576 
   577 
   578 
   579 //! @SYMTestCaseID 		SEC-SCAF-G004
   580 //! @SYMTestCaseDesc 		SPSA - Usage of key stream sink
   581 //! 				(spsa_keystreamsinks)
   582 //! @SYMPREQ 			PREQ782
   583 //! @SYMREQ 			
   584 //! @SYMTestPriority 		High
   585 //! @SYMTestStatus   		Implemented
   586 //! @SYMTestActions  		Preconditions:
   587 //!				• The necessary ROM based ‘single process’ stream agent plug-in is present that supports
   588 //!				the SDP media description supplied during construction of the key stream decoder.
   589 //!				• The required Rights Object file is present in the private folder for the supporting single
   590 //!				process stream agent.
   591 //!
   592 //!				Test Actions:
   593 //!				• Run the test step actions as described in test case SEC-SCAF-C001.				
   594 //!
   595 //! @SYMTestExpectedResults 	• The expected plain text string is found in the predefined location.
   596 //!
   597 //! @SYMTestType 		CIT
   598 
   599 START_TESTCASE SEC-SCAF-G004
   600 
   601 // Single Process Stream Agent Invoked
   602 RUN_TEST_STEP 100 tscaf SCAFKeyStreamSink z:\tcaf\tscaf\tscaf.ini spsa_keystreamink
   603 
   604 // 2 Single Process Stream Agents Invoked
   605 RUN_TEST_STEP 100 tscaf SCAFConcurrentKeyStreamSinks z:\tcaf\tscaf\tscaf.ini spsa_concurrent_keystreamsinks
   606 
   607 // 1 Single Process Stream Agent and 1 Client/Server Stream Agent Invoked
   608 RUN_TEST_STEP 100 tscaf SCAFConcurrentKeyStreamSinks z:\tcaf\tscaf\tscaf.ini spsa_cssa_concurrent_keystreamsinks
   609 
   610 END_TESTCASE SEC-SCAF-G004
   611 
   612 
   613 
   614 //! @SYMTestCaseID 		SEC-SCAF-G006
   615 //! @SYMTestCaseDesc 		SPSA - Testing IPSec integration with key stream decoder
   616 //! 				(spsa_ipsec_integration_decoder_automatic)
   617 //! @SYMPREQ 			PREQ782
   618 //! @SYMREQ 			
   619 //! @SYMTestPriority 		High
   620 //! @SYMTestStatus   		Implemented
   621 //! @SYMTestActions 		Preconditions:
   622 //!				• The necessary ROM based ‘single process’ stream agent plug-in is present that supports the
   623 //!				SDP media description supplied during construction of the key stream decoder.
   624 //!
   625 //!				Test Actions:
   626 //!				• Run the test step actions as described in test case SEC-SCAF-E015.
   627 //!
   628 //! @SYMTestExpectedResults 	• Associations was added 
   629 //!
   630 //! @SYMTestType 		CIT
   631 
   632 START_TESTCASE SEC-SCAF-G006
   633 
   634 RUN_TEST_STEP tscaf SCAFSetupRightsObjects z:\tcaf\tscaf\tscaf.ini Rights_Program_SingleProcessAgent
   635 
   636 //The time limit is disabled since this test is manual
   637 RUN_TEST_STEP -1 tscaf SCAFIpSecDecoderIntegration z:\tcaf\tscaf\tscaf.ini spsa_ipsec_integration_decoder_automatic
   638 
   639 END_TESTCASE SEC-SCAF-G006
   640 
   641 
   642 
   643 //********************** SEC-SCAF-H : REFERENCE AGENT TEST  **********************
   644 
   645 
   646 //! @SYMTestCaseID 		SEC-SCAF-H001
   647 //! @SYMTestCaseDesc 		Smoke testing for the Reference Agent
   648 //! 				(referenceagent)
   649 //! @SYMPREQ 			PREQ782
   650 //! @SYMREQ 			-------
   651 //! @SYMTestPriority 		Critical
   652 //! @SYMTestStatus   		Implemented
   653 //! @SYMTestActions  		
   654 //!				•	Generate a IPSec protected key stream description. 
   655 //!				•	Create a key stream sink from the protected key stream description.
   656 //!				•	Create a key stream decoder from an SDP message requiring the reference agent 
   657 //!					and the key stream sink.
   658 //!				•	Create a short term key message and write it to a predefined socket.
   659 //! @SYMTestExpectedResults 	
   660 //!				• Interfaces are invoked without leaves and panics.
   661 //!
   662 //! @SYMTestType 		CIT
   663 
   664 START_TESTCASE SEC-SCAF-H001
   665 
   666 RUN_TEST_STEP 100 tscaf SCAFRefAgent z:\tcaf\tscaf\tscaf.ini reference_agent
   667 
   668 END_TESTCASE SEC-SCAF-H001