forked from canada-ca/tracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathschema.faker.graphql
More file actions
2503 lines (2307 loc) · 79.8 KB
/
schema.faker.graphql
File metadata and controls
2503 lines (2307 loc) · 79.8 KB
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
# Exposes a URL that specifies the behaviour of this scalar.
directive @specifiedBy(
# The URL that specifies the behaviour of this scalar.
url: String!
) on SCALAR
# A field whose value is an upper case letter or an under score that has a length between 1 and 50.
scalar Acronym
# User Affiliations containing the permission level for the given organization,
# the users information, and the organizations information.
type Affiliation implements Node {
# The ID of an object
id: ID!
# User's level of access to a given organization.
permission: RoleEnums @examples(values: ["SUPER_ADMIN", "ADMIN", "USER"])
# The affiliated users information.
user: SharedUser
# The affiliated organizations information.
organization: Organization
}
# A connection to a list of items.
type AffiliationConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [AffiliationEdge] @listLength(min: 0, max: 5)
# The total amount of affiliations the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type AffiliationEdge {
# The item at the end of the edge
node: Affiliation
# A cursor for use in pagination
cursor: String!
}
# This object is used to inform the user if any errors occurred during authentication.
type AuthenticateError {
# Error code to inform user what the issue is related to.
code: Int
# Description of the issue that was encountered.
description: String
}
input AuthenticateInput {
# Security code found in text msg, or email inbox.
authenticationCode: Int!
# The JWT that is retrieved from the sign in mutation.
authenticateToken: String!
clientMutationId: String
}
type AuthenticatePayload {
# Authenticate union returning either a `authResult` or `authenticateError` object.
result: AuthenticateUnion
clientMutationId: String
}
# This union is used with the `authenticate` mutation, allowing for the
# user to authenticate, and support any errors that may occur
union AuthenticateUnion = AuthResult | AuthenticateError
# An object used to return information when users sign up or authenticate.
type AuthResult {
# JWT used for accessing controlled content.
authToken: String
# User that has just been created or signed in.
user: PersonalUser
}
# This object contains the list of different categories for pre-computed
# summary data with the computed total for how many domains in total are
# being compared.
type CategorizedSummary {
# List of SummaryCategory objects with data for different computed categories.
categories: [SummaryCategory] @listLength(min: 2, max: 2)
# Total domains that were check under this summary.
total: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# This object displays the percentages of the category totals.
type CategoryPercentages {
# Percentage of messages that are failing all checks.
failPercentage: Float @examples(values: [25.64, 57.89, 54.38, 93.48])
# Percentage of messages that are passing all checks.
fullPassPercentage: Float @examples(values: [25.64, 57.89, 54.38, 93.48])
# Percentage of messages that are passing only dkim.
passDkimOnlyPercentage: Float @examples(values: [25.64, 57.89, 54.38, 93.48])
# Percentage of messages that are passing only spf.
passSpfOnlyPercentage: Float @examples(values: [25.64, 57.89, 54.38, 93.48])
# The total amount of messages sent by this domain.
totalMessages: Int @examples(values: [86954, 57896, 54386, 93456, 23452])
}
# This object displays the total amount of messages that fit into each category.
type CategoryTotals {
# Amount of messages that are passing SPF, but failing DKIM.
passSpfOnly: Int @examples(values: [8694, 5896, 5436, 9345, 2345])
# Amount of messages that are passing DKIM, but failing SPF.
passDkimOnly: Int @examples(values: [8694, 5896, 5436, 9345, 2345])
# Amount of messages that are passing SPF and DKIM.
fullPass: Int @examples(values: [8694, 5896, 5436, 9345, 2345])
# Amount of messages that fail both SPF and DKIM.
fail: Int @examples(values: [8694, 5896, 5436, 9345, 2345])
}
type CreateDomainPayload {
# `CreateDomainUnion` returning either a `Domain`, or `DomainError` object.
result: CreateDomainUnion
clientMutationId: String
}
# This union is used with the `CreateDomain` mutation,
# allowing for users to create a domain and add it to their org,
# and support any errors that may occur
union CreateDomainUnion = DomainError | Domain
# This object is used to inform the user if any errors occurred while creating a domain.
type DomainError {
# Error code to inform user what the issue is related to.
code: Int
# Description of the issue that was encountered.
description: String
}
input CreateDomainInput {
# The global id of the organization you wish to assign this domain to.
orgId: ID!
# Url that you would like to be added to the database.
domain: DomainScalar!
# DKIM selector strings corresponding to this domain.
selectors: [Selector]
clientMutationId: String
}
type CreateOrganizationPayload {
# `CreateOrganizationUnion` returning either an `Organization`, or `OrganizationError` object.
result: CreateOrganizationUnion
clientMutationId: String
}
# This union is used with the `CreateOrganization` mutation,
# allowing for users to create an organization, and support any errors that may occur
union CreateOrganizationUnion = OrganizationError | Organization
# This object is used to inform the user if any errors occurred while using an organization mutation.
type OrganizationError {
# Error code to inform user what the issue is related to.
code: Int
# Description of the issue that was encountered.
description: String
}
input CreateOrganizationInput {
# The English acronym of the organization.
acronymEN: Acronym!
# The French acronym of the organization.
acronymFR: Acronym!
# The English name of the organization.
nameEN: String!
# The French name of the organization.
nameFR: String!
# The English translation of the zone the organization belongs to.
zoneEN: String!
# The English translation of the zone the organization belongs to.
zoneFR: String!
# The English translation of the sector the organization belongs to.
sectorEN: String!
# The French translation of the sector the organization belongs to.
sectorFR: String!
# The English translation of the country the organization resides in.
countryEN: String!
# The French translation of the country the organization resides in.
countryFR: String!
# The English translation of the province the organization resides in.
provinceEN: String!
# The French translation of the province the organization resides in.
provinceFR: String!
# The English translation of the city the organization resides in.
cityEN: String!
# The French translation of the city the organization resides in.
cityFR: String!
clientMutationId: String
}
# A date-time string at UTC, such as 2007-12-03T10:15:30Z, compliant with the
# `date-time` format outlined in section 5.6 of the RFC 3339 profile of the ISO
# 8601 standard for representation of dates and times using the Gregorian calendar.
scalar Date
# Object that contains the various senders and details for each category.
type DetailTables {
# List of senders that are failing DKIM checks.
dkimFailure(
after: String
first: Int
before: String
last: Int
): DkimFailureTableConnection
# List of senders that are failing DMARC checks.
dmarcFailure(
after: String
first: Int
before: String
last: Int
): DmarcFailureTableConnection
# List of senders that are passing all checks.
fullPass(
after: String
first: Int
before: String
last: Int
): FullPassTableConnection
# List of senders that are failing SPF checks.
spfFailure(
after: String
first: Int
before: String
last: Int
): SpfFailureTableConnection
}
# DomainKeys Identified Mail (DKIM) permits a person, role, or
# organization that owns the signing domain to claim some
# responsibility for a message by associating the domain with the
# message. This can be an author's organization, an operational relay,
# or one of their agents.
type DKIM implements Node {
# The ID of an object
id: ID!
# The domain the scan was ran on.
domain: Domain
# The time when the scan was initiated.
timestamp: Date @fake(type: pastDate)
# Individual scans results for each dkim selector.
results(
after: String
first: Int
before: String
last: Int
): DKIMResultConnection
}
# Ordering options for DKIM connections.
input DKIMOrder {
# The field to order DKIM scans by.
field: DKIMOrderField!
# The ordering direction.
direction: OrderDirection!
}
# Properties by which DKIM connections can be ordered.
enum DKIMOrderField {
# Order DKIM edges by timestamp.
TIMESTAMP
}
# A connection to a list of items.
type DKIMConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DKIMEdge] @listLength(min: 0, max: 5)
# The total amount of dkim scans related to a given domain.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DKIMEdge {
# The item at the end of the edge
node: DKIM
# A cursor for use in pagination
cursor: String!
}
# This table contains the data fields for senders who are in the DKIM fail category.
type DkimFailureTable {
# The ID of the object.
id: ID
# Is DKIM aligned.
dkimAligned: Boolean @examples(values: [true, false])
# Domains used for DKIM validation
dkimDomains: String @examples(values: ["test.dkim.gc.ca", "test.dkim.canada.ca"])
# The results of DKIM verification of the message. Can be pass, fail, neutral, temp-error, or perm-error.
dkimResults: String @examples(values: ["", "fail", "permerror"])
# Pointer to a DKIM public key record in DNS.
dkimSelectors: String @examples(values: ["selector1", "selector2", "selector3"])
# Host from reverse DNS of source IP address.
dnsHost: String @examples(values: ["test.dns.gc.ca", "test.dns.canada.ca"])
# Domain from SMTP banner message.
envelopeFrom: String @examples(values: ["test.envelope.gc.ca", "test.envelope.canada.ca"])
# Guidance for any issues that were found from the report.
guidance: String @examples(values: ["agg-dkim-failed", "agg-dkim-strict", "agg-dkim-unsigned"])
# The address/domain used in the "From" field.
headerFrom: String @examples(values: ["test.header.gc.ca", "test.header.canada.ca"])
# IP address of sending server.
sourceIpAddress: String @examples(values: ["123.456.78.91", "987.654.32.19"])
# Total messages from this sender.
totalMessages: Int @examples(values: [1247, 5687])
}
# A connection to a list of items.
type DkimFailureTableConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DkimFailureTableEdge] @listLength(min: 0, max: 5)
# The total amount of dkim failure the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DkimFailureTableEdge {
# The item at the end of the edge
node: DkimFailureTable
# A cursor for use in pagination
cursor: String!
}
# Individual scans results for the given dkim selector.
type DKIMResult implements Node {
# The ID of an object
id: ID!
# The dkim scan information that this result belongs to.
dkim: DKIM
# The selector the scan was ran on.
selector: String @examples(values: ["selector1", "selector2", "selector3"])
# DKIM record retrieved during the scan of the domain.
record: String @examples(
values: [
"v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC3rvAQg9bl72tae1RFu4zdx1ZE4E8VUbQfxDcm;"
]
)
# Size of the Public Key in bits
keyLength: String @examples(values: ["sub1024", "1024", "2048", "2048plus"])
# Raw scan result.
rawJson: JSON
# Guidance tags found during scan.
guidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
@deprecated(
reason: "This has been sub-divided into neutral, negative, and positive tags."
)
# Negative guidance tags found during scan.
negativeGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Neutral guidance tags found during scan.
neutralGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Positive guidance tags found during scan.
positiveGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
}
# A connection to a list of items.
type DKIMResultConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DKIMResultEdge] @listLength(min: 0, max: 5)
# The total amount of dkim results related to a given domain.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DKIMResultEdge {
# The item at the end of the edge
node: DKIMResult
# A cursor for use in pagination
cursor: String!
}
# Domain-based Message Authentication, Reporting, and Conformance
# (DMARC) is a scalable mechanism by which a mail-originating
# organization can express domain-level policies and preferences for
# message validation, disposition, and reporting, that a mail-receiving
# organization can use to improve mail handling.
type DMARC implements Node {
# The ID of an object
id: ID!
# The domain the scan was ran on.
domain: Domain
# The time when the scan was initiated.
timestamp: Date @fake(type: pastDate)
# DMARC phase found during scan.
dmarcPhase: Int @examples(values: [1, 2, 3, 4])
# DMARC record retrieved during scan.
record: String @examples(
values: [
"v=DMARC1; p=none; pct=100; rua=mailto:dmarc@cyber.gc.ca; ruf=mailto:dmarc@cyber.gc.ca; fo=1"
"v=DMARC1; p=none; sp=none; rua=mailto:dmarc@cyber.gc.ca"
]
)
# The requested policy you wish mailbox providers to apply
# when your email fails DMARC authentication and alignment checks.
pPolicy: String @examples(values: ["none", "missing", "quarantine", "reject"])
# This tag is used to indicate a requested policy for all
# subdomains where mail is failing the DMARC authentication and alignment checks.
spPolicy: String @examples(values: ["none", "missing", "quarantine", "reject"])
# The percentage of messages to which the DMARC policy is to be applied.
pct: Int @examples(values: [0, 20, 60, 70, 90, 100])
# Raw scan result.
rawJson: JSON
# Guidance tags found during DMARC Scan.
guidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
@deprecated(
reason: "This has been sub-divided into neutral, negative, and positive tags."
)
# Negative guidance tags found during DMARC Scan.
negativeGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Neutral guidance tags found during DMARC Scan.
neutralGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Positive guidance tags found during DMARC Scan.
positiveGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
}
# Ordering options for DMARC connections.
input DMARCOrder {
# The field to order DMARC scans by.
field: DmarcOrderField!
# The ordering direction.
direction: OrderDirection!
}
# Properties by which dmarc connections can be ordered.
enum DmarcOrderField {
# Order dmarc summaries by timestamp.
TIMESTAMP
# Order dmarc summaries by record.
RECORD
# Order dmarc summaries by p policy.
P_POLICY
# Order dmarc summaries by sp policy.
SP_POLICY
# Order dmarc summaries by percentage.
PCT
}
# A connection to a list of items.
type DMARCConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DMARCEdge] @listLength(min: 0, max: 5)
# The total amount of dmarc scans related to a given domain.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DMARCEdge {
# The item at the end of the edge
node: DMARC
# A cursor for use in pagination
cursor: String!
}
# This table contains the data fields for senders who are in the DMARC failure category.
type DmarcFailureTable {
# The ID of the object
id: ID
# Domains used for DKIM validation
dkimDomains: String @examples(values: ["test.dkim.gc.ca", "test.dkim.canada.ca"])
# Pointer to a DKIM public key record in DNS.
dkimSelectors: String @examples(values: ["selector1", "selector2", "selector3"])
# The DMARC enforcement action that the receiver took, either none, quarantine, or reject.
disposition: String @examples(values: ["none", "quarantine", "reject"])
# Host from reverse DNS of source IP address.
dnsHost: String @examples(values: ["test.dns.gc.ca", "test.dns.canada.ca"])
# Domain from SMTP banner message.
envelopeFrom: String @examples(values: ["test.envelope.gc.ca", "test.envelope.canada.ca"])
# The address/domain used in the "From" field.
headerFrom: String @examples(values: ["test.header.gc.ca", "test.header.canada.ca"])
# IP address of sending server.
sourceIpAddress: String @examples(values: ["123.456.78.91", "987.654.32.19"])
# Domains used for SPF validation.
spfDomains: String @examples(values: ["test.spf.gc.ca", "test.spf.canada.ca"])
# Total messages from this sender.
totalMessages: Int @examples(values: [1247, 5687])
}
# A connection to a list of items.
type DmarcFailureTableConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DmarcFailureTableEdge] @listLength(min: 0, max: 5)
# The total amount of dmarc failures the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DmarcFailureTableEdge {
# The item at the end of the edge
node: DmarcFailureTable
# A cursor for use in pagination
cursor: String!
}
# Object that contains information for a dmarc summary.
type DmarcSummary implements Node {
# The ID of an object
id: ID!
# The domain that the data in this dmarc summary belongs to.
domain: Domain
# Start date of data collection.
month: PeriodEnums
# End date of data collection.
year: Year
# Category percentages based on the category totals.
categoryPercentages: CategoryPercentages
# Category totals for quick viewing.
categoryTotals: CategoryTotals
# Various senders for each category.
detailTables: DetailTables
}
# A connection to a list of items.
type DmarcSummaryConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DmarcSummaryEdge] @listLength(min: 5, max: 10)
# The total amount of dmarc summaries the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DmarcSummaryEdge {
# The item at the end of the edge
node: DmarcSummary
# A cursor for use in pagination
cursor: String!
}
# Ordering options for dmarc summary connections.
input DmarcSummaryOrder {
# The field to order dmarc summaries by.
field: DmarcSummaryOrderField!
# The ordering direction.
direction: OrderDirection!
}
# Properties by which dmarc summary connections can be ordered.
enum DmarcSummaryOrderField {
# Order dmarc summaries by fail count.
FAIL
# Order dmarc summaries by pass count.
FULL_PASS
# Order dmarc summaries by pass dkim only count.
PASS_DKIM_ONLY
# Order dmarc summaries by pass spf only count.
PASS_SPF_ONLY
# Order dmarc summaries by fail percentage.
FAIL_PERCENTAGE
# Order dmarc summaries by pass percentage.
FULL_PASS_PERCENTAGE
# Order dmarc summaries by pass dkim only percentage.
PASS_DKIM_ONLY_PERCENTAGE
# Order dmarc summaries by spf only percentage.
PASS_SPF_ONLY_PERCENTAGE
# Order dmarc summaries by total messages
TOTAL_MESSAGES
# Order dmarc summaries by their respective domains.
DOMAIN
}
# Domain object containing information for a given domain.
type Domain implements Node {
# The ID of an object
id: ID!
# Domain that scans will be ran on.
domain: DomainScalar @examples(
values: [
"javascript:alert('XSS')"
"javascript:eval('aler'+(!![]+[])[+[]])('xss')"
"rcmp-grc.gc.ca"
"tbs-sct.gc.ca"
"canada.ca"
"cra-arc.gc.ca"
"pm.gc.ca"
"cse-cst.gc.ca"
"forces.gc.ca"
"jAva	script:alert('XSS')"
"cra.arc.gc.ca"
"cra-arc.gc.ca"
"cse-cst.gc.ca"
"cyber.gc.ca"
"dfait-maeci.gc.ca"
"dfo-mpo.gc.ca"
"ec.gc.ca"
"forces.gc.ca"
"gccollab.ca"
"gccollaboration.ca"
"goc-gdc.ca"
"hc-sc.gc.ca"
]
)
# The last time that a scan was ran on this domain.
lastRan: String @fake(type: recentDate)
# DMARC phase found during scan.
dmarcPhase: String @examples(values: ["maintain", "deploy", "not implemented"])
# Whether or not the domain has a aggregate dmarc report.
hasDMARCReport: Boolean
# Domain Keys Identified Mail (DKIM) selector strings associated with domain.
selectors: [Selector] @listLength(min: 0, max: 2)
# The domains scan status, based on the latest scan data.
status: DomainStatus
# The organization that this domain belongs to.
organizations(
# Ordering options for organization connections
orderBy: OrganizationOrder
# String argument used to search for organizations.
search: String
after: String
first: Int
before: String
last: Int
): OrganizationConnection
# DKIM, DMARC, and SPF scan results.
email: EmailScan
# HTTPS, and SSL scan results.
web: WebScan
# Summarized DMARC aggregate reports.
dmarcSummaryByPeriod(
# The month in which the returned data is relevant to.
month: PeriodEnums!
# The year in which the returned data is relevant to.
year: Year!
): DmarcSummary
# Yearly summarized DMARC aggregate reports.
yearlyDmarcSummaries: [DmarcSummary] @listLength(min: 13, max: 13)
}
# A connection to a list of items.
type DomainConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [DomainEdge] @listLength(min: 0, max: 5)
# The total amount of domains the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type DomainEdge {
# The item at the end of the edge
node: Domain
# A cursor for use in pagination
cursor: String!
}
# Ordering options for domain connections.
input DomainOrder {
# The field to order domains by.
field: DomainOrderField!
# The ordering direction.
direction: OrderDirection!
}
# Properties by which domain connections can be ordered.
enum DomainOrderField {
# Order domains by domain.
DOMAIN
# Order domains by last ran.
LAST_RAN
# Order domains by dkim status.
DKIM_STATUS
# Order domains by dmarc status.
DMARC_STATUS
# Order domains by https status.
HTTPS_STATUS
# Order domains by spf status.
SPF_STATUS
# Order domains by ssl status.
SSL_STATUS
}
# String that conforms to a domain structure.
scalar DomainScalar
# This object contains how the domain is doing on the various scans we preform, based on the latest scan data.
type DomainStatus {
# DKIM Status
dkim: StatusEnum
# DMARC Status
dmarc: StatusEnum
# HTTPS Status
https: StatusEnum
# SPF Status
spf: StatusEnum
# SSL Status
ssl: StatusEnum
}
# A field whose value conforms to the standard internet email address format as
# specified in RFC822: https://www.w3.org/Protocols/rfc822/.
scalar EmailAddress
# Results of DKIM, DMARC, and SPF scans on the given domain.
type EmailScan {
# The domain the scan was ran on.
domain: Domain
# DomainKeys Identified Mail (DKIM) Signatures scan results.
dkim(
# Start date for date filter.
startDate: Date
# End date for date filter.
endDate: Date
after: String
first: Int
before: String
last: Int
orderBy: DKIMOrder
): DKIMConnection
# Domain-based Message Authentication, Reporting, and Conformance (DMARC) scan results.
dmarc(
# Start date for date filter.
startDate: Date
# End date for date filter.
endDate: Date
after: String
first: Int
before: String
last: Int
orderBy: DMARCOrder
): DMARCConnection
# Sender Policy Framework (SPF) scan results.
spf(
# Start date for date filter.
startDate: Date
# End date for date filter.
endDate: Date
after: String
first: Int
before: String
last: Int
orderBy: SPFOrder
): SPFConnection
}
# This table contains the data fields for senders who are in the Full Pass category.
type FullPassTable {
# The ID of the object
id: ID
# Domains used for DKIM validation
dkimDomains: String @examples(values: ["test.dkim.gc.ca", "test.dkim.canada.ca"])
# Pointer to a DKIM public key record in DNS.
dkimSelectors: String @examples(values: ["selector1", "selector2", "selector3"])
# Host from reverse DNS of source IP address.
dnsHost: String @examples(values: ["test.dns.gc.ca", "test.dns.canada.ca"])
# Domain from SMTP banner message.
envelopeFrom: String @examples(values: ["test.envelope.gc.ca", "test.envelope.canada.ca"])
# The address/domain used in the "From" field.
headerFrom: String @examples(values: ["test.header.gc.ca", "test.header.canada.ca"])
# IP address of sending server.
sourceIpAddress: String @examples(values: ["123.456.78.91", "987.654.32.19"])
# Domains used for SPF validation.
spfDomains: String @examples(values: ["test.spf.gc.ca", "test.spf.canada.ca"])
# Total messages from this sender.
totalMessages: Int @examples(values: [1247, 5687])
}
# A connection to a list of items.
type FullPassTableConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [FullPassTableEdge] @listLength(min: 0, max: 5)
# The total amount of full passes the user has access to.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type FullPassTableEdge {
# The item at the end of the edge
node: FullPassTable
# A cursor for use in pagination
cursor: String!
}
# Details for a given guidance tag based on https://github.com/canada-ca/tracker/wiki/Guidance-Tags
type GuidanceTag implements Node {
# The ID of an object
id: ID!
# The guidance tag ID.
tagId: String @listLength(min: 0, max: 4)
@examples(
values: [
"dkim1"
"dkim2"
"dkim3"
"dkim4"
]
)
# The guidance tag name.
tagName: String @examples(
values: [
"DKIM-GC",
"DKIM-missing",
"DKIM-missing-mx-O365",
"DKIM-missing-O365-misconfigured"
]
)
# Guidance for changes to record, or to maintain current stance.
guidance: String @examples(
values: [
"Government of Canada domains subject to TBS guidelines",
"Follow implementation guide",
"DKIM record missing but MX uses O365. Follow cloud-specific guidance",
"DKIM CNAMEs do not exist, but MX points to *.onmicrosoft.com and SPF record includes O365.",
]
)
# Links to implementation guidance for a given tag.
refLinks: [RefLinks] @listLength(min: 0, max: 4)
# Links to technical information for a given tag.
refLinksTech: [RefLinks] @listLength(min: 0, max: 4)
}
# A connection to a list of items.
type GuidanceTagConnection {
# Information to aid in pagination.
pageInfo: PageInfo!
# A list of edges.
edges: [GuidanceTagEdge] @listLength(min: 0, max: 5)
# The total amount of guidance tags for a given scan type.
totalCount: Int @fake(
type: number
options: { minNumber: 0, maxNumber: 20, precisionNumber: 1 }
)
}
# An edge in a connection.
type GuidanceTagEdge {
# The item at the end of the edge
node: GuidanceTag
# A cursor for use in pagination
cursor: String!
}
# Ordering options for guidance tag connections.
input GuidanceTagOrder {
# The field to order guidance tags by.
field: GuidanceTagOrderField!
# The ordering direction.
direction: OrderDirection!
}
# Properties by which Guidance Tag connections can be ordered.
enum GuidanceTagOrderField {
# Order guidance tag edges by tag id.
TAG_ID
# Order guidance tag edges by tag name.
TAG_NAME
# Order guidance tag edges by tag guidance.
GUIDANCE
}
# Hyper Text Transfer Protocol Secure scan results.
type HTTPS implements Node {
# The ID of an object
id: ID!
# The domain the scan was ran on.
domain: Domain
# The time the scan was initiated.
timestamp: Date @fake(type: pastDate)
# State of the HTTPS implementation on the server and any issues therein.
implementation: String @examples(values: ["Valid HTTPS", "Downgrades HTTPS", "Bad Chain", "Bad Hostname"])
# Degree to which HTTPS is enforced on the server based on behaviour.
enforced: String @examples(values: ["Strict", "Moderate", "Weak", "Not Enforced"])
# Presence and completeness of HSTS implementation.
hsts: String @examples(values: ["HSTS Fully Implemented", "HSTS Max Age Too Short", "No HSTS"])
# Denotes how long the domain should only be accessed using HTTPS
hstsAge: String @examples(values: ["31622400", "21672901"])
# Denotes whether the domain has been submitted and included within HSTS preload list.
preloaded: String @examples(values: ["HSTS Preloaded", "HSTS Preload Ready", "HSTS Not Preloaded"])
# Raw scan result.
rawJson: JSON
# Guidance tags found during scan.
guidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
@deprecated(
reason: "This has been sub-divided into neutral, negative, and positive tags."
)
# Negative guidance tags found during scan.
negativeGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Neutral guidance tags found during scan.
neutralGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection
# Positive guidance tags found during scan.
positiveGuidanceTags(
# Ordering options for guidance tag connections
orderBy: GuidanceTagOrder
after: String
first: Int
before: String
last: Int
): GuidanceTagConnection