forked from OVALProject/Sandbox
-
Notifications
You must be signed in to change notification settings - Fork 0
/
x-android-definitions.xsd
1021 lines (1021 loc) · 75.7 KB
/
x-android-definitions.xsd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<?xml version="1.0" encoding="utf-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:oval="http://oval.mitre.org/XMLSchema/oval-common-5" xmlns:oval-def="http://oval.mitre.org/XMLSchema/oval-definitions-5" xmlns:android-def="http://oval.mitre.org/XMLSchema/oval-definitions-5#android" xmlns:sch="http://purl.oclc.org/dsdl/schematron" targetNamespace="http://oval.mitre.org/XMLSchema/oval-definitions-5#android" elementFormDefault="qualified" version="5.10">
<xsd:import namespace="http://oval.mitre.org/XMLSchema/oval-definitions-5" schemaLocation="oval-definitions-schema.xsd"/>
<xsd:import namespace="http://oval.mitre.org/XMLSchema/oval-common-5" schemaLocation="oval-common-schema.xsd"/>
<xsd:annotation>
<xsd:documentation>The following is a description of the elements, types, and attributes that compose the Android specific tests found in Open Vulnerability and Assessment Language (OVAL). Each test is an extension of the standard test element defined in the Core Definition Schema. Through extension, each test inherits a set of elements and attributes that are shared amongst all OVAL tests. Each test is described in detail and should provide the information necessary to understand what each element and attribute represents. This document is intended for developers and assumes some familiarity with XML. A high level description of the interaction between the different tests and their relationship to the Core Definition Schema is not outlined here.</xsd:documentation>
<xsd:documentation>The OVAL Schema is maintained by The MITRE Corporation and developed by the public OVAL Community. For more information, including how to get involved in the project and how to submit change requests, please visit the OVAL website at http://oval.mitre.org.</xsd:documentation>
<xsd:appinfo>
<schema>Android Definition</schema>
<version>5.10</version>
<date>6/22/2012 8:58:23 AM</date>
<terms_of_use>Copyright (c) 2002-2012, The MITRE Corporation. All rights reserved. The contents of this file are subject to the terms of the OVAL License located at http://oval.mitre.org/oval/about/termsofuse.html. See the OVAL License for the specific language governing permissions and limitations for use of this schema. When distributing copies of the OVAL Schema, this license header must be included.</terms_of_use>
<sch:ns prefix="oval-def" uri="http://oval.mitre.org/XMLSchema/oval-definitions-5"/>
<sch:ns prefix="android-def" uri="http://oval.mitre.org/XMLSchema/oval-definitions-5#android"/>
<sch:ns prefix="xsi" uri="http://www.w3.org/2001/XMLSchema-instance"/>
</xsd:appinfo>
</xsd:annotation>
<!-- =============================================================================== -->
<!-- ============================== SYSTEM DETAILS TEST =========================== -->
<!-- =============================================================================== -->
<xsd:element name="system_details_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The syste_details test is used to get system hardware and operating system information. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a system_details_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>system_details_test</oval:test>
<oval:object>system_details_object</oval:object>
<oval:state>system_details_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">system_details_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_system_details_test">
<sch:rule context="android-def:system_details_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:system_details_object/@id"><sch:value-of select="../@id"/> - the object child element of system_details_test must reference system_details_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:system_details_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:system_details_state/@id"><sch:value-of select="../@id"/> - the state child element of an system_details_test must reference an system_details_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="system_details_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The system_details_object element is used by a system_details test to define the object to be evaluated. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="system_details_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The system_details_state element defines the information about the hardware and the operating system. Please refer to the individual elements in the schema for more details about what each represents.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="hardware" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The hardware model.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="manufacturer" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The device manufacturer.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="model" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The device model identifier.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="product" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The product name.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="cpu_abi" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The CPU architecture.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="build_fingerprint" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Build fingerprint.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="os_version_code_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Operating system version code.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="os_version_build_number" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Operating system build number.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="os_version_release_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Operating system release name.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="os_version_sdk_number" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Operating system SDK number.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- ================================ CAMERA TEST ================================ -->
<!-- =============================================================================== -->
<xsd:element name="camera_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The camera_test is used to check if Camera is enabled on the device. </xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>camera_test</oval:test>
<oval:object>camera_object</oval:object>
<oval:state>camera_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">camera_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_cmrtst">
<sch:rule context="android-def:camera_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:camera_object/@id"><sch:value-of select="../@id"/> - the object child element of a camera_test must reference a camera_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:camera_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:camera_state/@id"><sch:value-of select="../@id"/> - the state child element of a camera_test must reference a camera_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="camera_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The camera_object element is used by a camera test to define those objects to evaluate based on a camera state.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="camera_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The camera_state element contains a single entity that is used to check the status of the camera. </xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="current_status" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The current_status entity is used to check the state of the Camera device.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =========================== PASSWORD TEST ================================= -->
<!-- =============================================================================== -->
<xsd:element name="password_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The password test is used to check specific policy associated with passwords. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a password_object and the optional state element specifies the metadata to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>password_test</oval:test>
<oval:object>password_object</oval:object>
<oval:state>password_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">password_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_ptst">
<sch:rule context="android-def:password_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:password_object/@id"><sch:value-of select="../@id"/> - the object child element of a password_test must reference a password_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:password_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:password_state/@id"><sch:value-of select="../@id"/> - the state child element of a password_test must reference a password_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="password_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The password_object element is used by a password test to define those objects to evaluated based on a specified state. Any OVAL Test written to check password policy will reference the same password_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="password_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The password_state element specifies the various policies associated with passwords. A password test will reference a specific instance of this state that defines the exact settings that need to be evaluated.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="max_num_failed_user_auth" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Maximum number of failed user authentications before device wipe.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_hist" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Specifies the length of password history maintained.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_quality" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Signifies whether passwords must meet the complexity requirements put forth by the operating system.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_max_length" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Maximum number of characters allowed in a password.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_length" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum length characters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_letters" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of letters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_lower_case_letters" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of lower case letters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_non_letters" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of non-letter characters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_numeric" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of numeric characters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_symbols" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of symbol characters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_min_upper_case_letters" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Minimum number of upper case letters password must have.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_expiration" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Password expiration timeout.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="password_visible" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>A boolean value that specify if password characters must be shown while keying in.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== ENCRYPTION SETTING TEST ===================== -->
<!-- =============================================================================== -->
<xsd:element name="encryption_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The encryption_test is used to check the encryption status on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a encryption_object and the optional state element references a encryption_state that specifies the information to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>encryption_test</oval:test>
<oval:object>encryption_object</oval:object>
<oval:state>encryption_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">encryption_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_encryptiontst">
<sch:rule context="android-def:encryption_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:encryption_object/@id"><sch:value-of select="../@id"/> - the object child element of a encryption_test must reference a encryption_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:encryption_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:encryption_state/@id"><sch:value-of select="../@id"/> - the state child element of a encryption_test must reference a encryption_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="encryption_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The encryption_object element is used by a encryption test to define those objects to evaluated based on a specified state. Any OVAL Test written to check password policy will reference the same password_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="encryption_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The encryption_state element defines the encryption settings configured on the device.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="encryption_status" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Enabled encryption setting.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="storage_encryption_status" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Enabled encryption setting.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== DEVICE ACCESS TEST ========================== -->
<!-- =============================================================================== -->
<xsd:element name="device_access_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The device_access_test is used to check the device accessibility information. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a device_access_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>device_access_test</oval:test>
<oval:object>device_access_object</oval:object>
<oval:state>device_access_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">device_access_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_device_access_test">
<sch:rule context="android-def:device_access_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:device_access_object/@id"><sch:value-of select="../@id"/> - the object child element of an device_access_test must reference an device_access_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:device_access_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:device_access_state/@id"><sch:value-of select="../@id"/> - the state child element of an device_access_test must reference an device_access_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="device_access_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The device_access_object element is used by a device access test to define those objects to evaluated based on a specified state. Any OVAL Test written to check device accessibility will reference the same device_access_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="device_access_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The device_access_state element defines the accessibility information.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="screen_lock_timeout" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Time out in seconds before the screen locks</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== LOCATION SERVICE TEST ======================= -->
<!-- =============================================================================== -->
<xsd:element name="location_service_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The location_service_test is used to check the status of location based services. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a location_service_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>location_service_test</oval:test>
<oval:object>location_service_object</oval:object>
<oval:state>location_service_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">location_service_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_location_service_test">
<sch:rule context="android-def:location_service_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:location_service_object/@id"><sch:value-of select="../@id"/> - the object child element of an location_service_test must reference an location_service_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:location_service_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:location_service_state/@id"><sch:value-of select="../@id"/> - the state child element of an location_service_test must reference an location_service_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="location_service_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The location_service_object element is used by a location service test to define those objects to evaluated based on a specified state. Any OVAL Test written to check location based services status will reference the same location_service_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="location_service_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The location_service_state element defines the location based services status.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="gps_enabled" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>A boolean value indicating GPS status.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="network" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Configured to use the network.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== WIFI TEST ==================================== -->
<!-- =============================================================================== -->
<xsd:element name="wifi_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The wifi_test is used to check the status of general WIFI settings on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a wifi_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>wifi_test</oval:test>
<oval:object>wifi_object</oval:object>
<oval:state>wifi_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">wifi_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_wifi_test">
<sch:rule context="android-def:wifi_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:wifi_object/@id"><sch:value-of select="../@id"/> - the object child element of an wifi_test must reference an wifi_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:wifi_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:wifi_state/@id"><sch:value-of select="../@id"/> - the state child element of an wifi_test must reference an wifi_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="wifi_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The wifi_object element is used by a wifi test to define those objects to evaluated based on a specified state. Any OVAL Test written to check wifi settings status will reference the same wifi_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="wifi_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The wifi_state element defines the wifi general settings status.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="wifi_status" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Is WIFI enabled.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="network_availability_notification" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>A boolean value indicating WIFI network availability notification setting.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="open_networkds" type="oval-def:EntityStateIntType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>An integer value indicating number of open networks kept.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== WIFI SECURITY TEST =========================== -->
<!-- =============================================================================== -->
<xsd:element name="wifi_security_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The wifi_security_test is used to check the status of general WIFI security settings on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a wifi_security_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>wifi_security_test</oval:test>
<oval:object>wifi_security_object</oval:object>
<oval:state>wifi_security_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">wifi_security_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_wifi_security_test">
<sch:rule context="android-def:wifi_security_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:wifi_security_object/@id"><sch:value-of select="../@id"/> - the object child element of an wifi_security_test must reference an wifi_security_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:wifi_security_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:wifi_security_state/@id"><sch:value-of select="../@id"/> - the state child element of an wifi_security_test must reference an wifi_security_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="wifi_security_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The wifi_security_object element is used by a wifi_security_test to define the SSID of the WIFI to verify security settings. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="android-def_wifi_security_object_verify_filter_state">
<sch:rule context="android-def:wifi_security_object//oval-def:filter">
<sch:let name="parent_object" value="ancestor::android-def:wifi_security_object"/>
<sch:let name="parent_object_id" value="$parent_object/@id"/>
<sch:let name="state_ref" value="."/>
<sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
<sch:let name="state_name" value="local-name($reffed_state)"/>
<sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
<sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#android') and ($state_name='wifi_security_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType">
<xsd:sequence>
<xsd:choice>
<xsd:element ref="oval-def:set"/>
<xsd:sequence>
<xsd:element name="ssid" type="oval-def:EntityObjectStringType">
<xsd:annotation>
<xsd:documentation>The network's SSID to check.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:choice>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="wifi_security_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The wifi_security_state element defines the wifi security settings status.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="ssid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The network's SSID.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="bssid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>BSSID. The value is a string in the format of an Ethernet MAC address.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="auth_algorithms" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The set of authentication protocols supported by this configuration.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="group_ciphers" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The set of group ciphers supported by this configuration.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="key_management" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The set of key management protocols supported by this configuration.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="pairwise_ciphers" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The set of pairwise ciphers for WPA supported by this configuration.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="protocols" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The set of security protocols supported by this configuration.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="hidden_ssid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>This is a network that does not broadcast its SSID.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="network_id" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The ID number that the supplicant uses to identify this network configuration entry.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="priority" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Priority determines the preference given to a network by wpa_supplicant when choosing an access point with which to associate.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="current_status" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>The current status of this network configuration entry.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== BLUETOOTH TEST =============================== -->
<!-- =============================================================================== -->
<xsd:element name="bluetooth_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The bluetooth_test is used to check the status of bluetooth settings on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a bluetooth_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>bluetooth_test</oval:test>
<oval:object>bluetooth_object</oval:object>
<oval:state>bluetooth_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">bluetooth_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_bluetooth_test">
<sch:rule context="android-def:bluetooth_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:bluetooth_object/@id"><sch:value-of select="../@id"/> - the object child element of an bluetooth_test must reference an bluetooth_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:bluetooth_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:bluetooth_state/@id"><sch:value-of select="../@id"/> - the state child element of an bluetooth_test must reference an bluetooth_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="bluetooth_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The bluetooth_object element is used by a bluetooth test to define those objects to be evaluated based on a specified state. Any OVAL Test written to check bluetooth settings status will reference the same bluetooth_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="bluetooth_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The bluetooth_state element defines the bluetooth general settings status.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="discoverable" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Device Bluetooth is discoverable?</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="current_status" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Bluetooth is enabled?</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== APPLICATION MANAGER TEST ===================== -->
<!-- =============================================================================== -->
<xsd:element name="app_manager_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The app_manager_test is used to verify the applications installed on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a app_manager_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>app_manager_test</oval:test>
<oval:object>app_manager_object</oval:object>
<oval:state>app_manager_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">app_manager_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_app_manager_test">
<sch:rule context="android-def:app_manager_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:app_manager_object/@id"><sch:value-of select="../@id"/> - the object child element of an app_manager_test must reference an app_manager_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:app_manager_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:app_manager_state/@id"><sch:value-of select="../@id"/> - the state child element of an app_manager_test must reference an app_manager_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="app_manager_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The app_manager_object element is used by a app_manager_test to define the required application properties to verify. Each object extends the standard ObjectType as defined in the oval-definitions-schema and one should refer to the ObjectType description for more information.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="android-def_app_manager_object_verify_filter_state">
<sch:rule context="android-def:app_manager_object//oval-def:filter">
<sch:let name="parent_object" value="ancestor::android-def:app_manager_object"/>
<sch:let name="parent_object_id" value="$parent_object/@id"/>
<sch:let name="state_ref" value="."/>
<sch:let name="reffed_state" value="ancestor::oval-def:oval_definitions/oval-def:states/*[@id=$state_ref]"/>
<sch:let name="state_name" value="local-name($reffed_state)"/>
<sch:let name="state_namespace" value="namespace-uri($reffed_state)"/>
<sch:assert test="(($state_namespace='http://oval.mitre.org/XMLSchema/oval-definitions-5#android') and ($state_name='app_manager_state'))">State referenced in filter for <sch:value-of select="name($parent_object)"/> '<sch:value-of select="$parent_object_id"/>' is of the wrong type. </sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType">
<xsd:sequence>
<xsd:choice>
<xsd:element ref="oval-def:set"/>
<xsd:sequence>
<xsd:element name="application_name" type="oval-def:EntityObjectStringType">
<xsd:annotation>
<xsd:documentation>Name of the application.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="process_name" type="oval-def:EntityObjectStringType">
<xsd:annotation>
<xsd:documentation>Name of the process that the application launches.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="package_name" type="oval-def:EntityObjectStringType">
<xsd:annotation>
<xsd:documentation>Name of the package.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element ref="oval-def:filter" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:choice>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="app_manager_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The app_manager_state element defines the application settings.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="application_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Name of the application.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="process_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Name of the process that the application launches.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="uid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Unique ID assigned to the application.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="gid" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Group id that the user belongs to in the underlying sandbox.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="user_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Name of the user correspoing to uid. Usually defaults to uid.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="package_name" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Name of the package.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="data_directory" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Data directory assigned to the application.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="version" type="oval-def:EntityStateVersionType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Application version.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="current_status" type="oval-def:EntityStateBoolType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Application is enabled or disabled.</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="permissions" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Comma separated list of permission that the app should be having in order to run as intended</xsd:documentation>
</xsd:annotation>
</xsd:element>
<xsd:element name="native_lib_dir" type="oval-def:EntityStateStringType" minOccurs="0" maxOccurs="1">
<xsd:annotation>
<xsd:documentation>Directory where its native libraries(if any) needs to be installed/copied.</xsd:documentation>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<!-- =============================================================================== -->
<!-- =============================== NETWORK TEST ================================= -->
<!-- =============================================================================== -->
<xsd:element name="network_test" substitutionGroup="oval-def:test">
<xsd:annotation>
<xsd:documentation>The network_test is used to check the status of network preferences on the device. It extends the standard TestType as defined in the oval-definitions-schema and one should refer to the TestType description for more information. The required object element references a network_object and the optional state element specifies the data to check.</xsd:documentation>
<xsd:appinfo>
<oval:element_mapping>
<oval:test>network_test</oval:test>
<oval:object>network_object</oval:object>
<oval:state>network_state</oval:state>
<oval:item target_namespace="http://oval.mitre.org/XMLSchema/oval-system-characteristics-5#android">network_item</oval:item>
</oval:element_mapping>
</xsd:appinfo>
<xsd:appinfo>
<sch:pattern id="android-def_network_test">
<sch:rule context="android-def:network_test/android-def:object">
<sch:assert test="@object_ref=ancestor::oval-def:oval_definitions/oval-def:objects/android-def:network_object/@id"><sch:value-of select="../@id"/> - the object child element of an network_test must reference an network_object</sch:assert>
</sch:rule>
<sch:rule context="android-def:network_test/android-def:state">
<sch:assert test="@state_ref=ancestor::oval-def:oval_definitions/oval-def:states/android-def:network_state/@id"><sch:value-of select="../@id"/> - the state child element of an network_test must reference an network_state</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:TestType">
<xsd:sequence>
<xsd:element name="object" type="oval-def:ObjectRefType"/>
<xsd:element name="state" type="oval-def:StateRefType" minOccurs="0" maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="network_object" substitutionGroup="oval-def:object">
<xsd:annotation>
<xsd:documentation>The network_object element is used by a network test to define those objects to be evaluated based on a specified state. Any OVAL Test written to check network preference will reference the same network_object which is basically an empty object element.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:ObjectType"/>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
<xsd:element name="network_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The network_state element defines the network preferences.</xsd:documentation>