-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathftress.h
2248 lines (1687 loc) · 89.7 KB
/
ftress.h
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
/**************************************************************************************************
File Name: ftress.h
Description: This file represents the 'public' interface to the 4TRESS C Client.
***************************************************************************************************/
#include <time.h>
#ifdef __cplusplus
extern "C" {
#endif
/* error codes */
#define FTRESS_SUCCESS 0 // No error
#define FTRESS_SVR_FAULT 2 // The service returned a server fault (SOAP 1.2 Receiver fault)
#define FTRESS_FATAL_ERROR 11 // Internal error
#define FTRESS_FAULT 12 // An exception raised by the service
#define FTRESS_NO_METHOD 13 // The dispatcher did not find a matching operation for the request
#define FTRESS_NO_DATA 14 // No data in HTTP message
#define FTRESS_GET_METHOD 15 // HTTP GET operation not handled
#define FTRESS_NULL 19 // An element was null, while it is not supposed to be null
#define FTRESS_TCP_ERROR 24 // A connection error occured
#define FTRESS_HTTP_ERROR 25 // An HTTP error occured
#define FTRESS_SSL_ERROR 26 // An SSL error occured
/* data types */
typedef void *Alsi;
typedef void *ChannelCode;
typedef void *SecurityDomain;
typedef void *UPAuthenticationRequest;
typedef void *AuthenticationRequestParameter;
typedef void *AuthenticationTypeCode;
typedef void *UserCode;
typedef void *AuthenticationResponse;
typedef void *MDPromptCode;
typedef void *PrimaryAuthenticateUPResponse;
typedef void *AuthenticationStatistics;
typedef void *AuthenticationResponseParameter;
typedef void *ArrayOfAuthenticationRequestParameter;
typedef void *ArrayOfMDPromptCode;
typedef void *ArrayOfInt;
typedef void *LogoutResponse;
typedef void *PrimaryAuthenticateDeviceResponse;
typedef void *DeviceAuthenticationRequest;
typedef void *DeviceSearchCriteria;
typedef void *DeviceGroupCode;
typedef void *ArrayOfDeviceGroupCode;
typedef void *DeviceId;
typedef void *DeviceTypeCode;
typedef void *DateRangeSearchCriteria;
typedef void *IndirectPrimaryAuthenticateUPResponse;
typedef void *IndirectPrimaryAuthenticateDeviceResponse;
typedef void *GetAuthenticationChallengeResponse;
typedef void *AuthenticationChallenge;
typedef void *SeedPositions;
typedef void *MDAuthenticationRequest;
typedef void *MDAuthenticationAnswer;
typedef void *MDAuthenticationPrompts;
typedef void *MDAuthenticationPrompt;
typedef void *ArrayOfMDAuthenticationAnswer;
typedef void *ArrayOfMDAuthenticationPrompt;
typedef void *GetMDAuthenticationPromptsResponse;
typedef void *IndirectPrimaryAuthenticateMDResponse;
typedef void *IndirectGetPasswordSeedPositionsResponse;
typedef void *ResetDeviceAuthenticatorFailedAuthenticationCountResponse;
typedef void *SearchDevicesResponse;
typedef void *DeviceSearchResults;
typedef void *ArrayOfDevices;
typedef void *Device;
typedef void *SDB;
typedef void *ArrayOfDeviceCredentialInfo;
typedef void *DeviceStatus;
typedef void *DeviceCredentialInfo;
typedef void *CredentialId;
typedef void *CredentialTypeCode;
/** ftress init */
const int ftress_init();
/** ftress quit */
const int ftress_quit();
/** ftress init ssl */
const int ftress_init_ssl();
/**
* Returns the error or exception string
*/
char * ftress_exception_handler(int result);
/*************************************************************************************
* ftress DTOs *
*************************************************************************************/
/*************************************************************************************
* ChannelCode *
*************************************************************************************/
/** Default constructor for Channel code */
ChannelCode ftress_channel_code_create_default();
/** Parameterised constructor for Channel code */
ChannelCode ftress_channel_code_create(char *code, int allChannels);
/** Setter for channel code */
const int ftress_channel_code_set_code(ChannelCode channelCode, char *code);
/** Getter for channel code*/
char * ftress_channel_code_get_code(ChannelCode channelCode);
/** Setter for all channels */
const int ftress_channel_code_set_all_channels(ChannelCode channelCode, int allChannels);
/** Getter for all channels */
int ftress_channel_code_get_all_channels(ChannelCode channelCode);
/** Free the Channel code */
const int ftress_channel_code_free(ChannelCode channelCode);
/*************************************************************************************
* SecurityDomain *
*************************************************************************************/
/** Default constructor for security domain */
SecurityDomain ftress_security_domain_create_default();
/** Parameterised constructor for security domain */
SecurityDomain ftress_security_domain_create(char *domainCode);
/** Getter for security domain */
char * ftress_security_domain_get_domain(SecurityDomain securityDomain);
/** Setter for security domain code */
const int ftress_security_domain_set_domain(SecurityDomain securityDomain, char *domain);
/** Getter for security domain code */
char * ftress_security_domain_get_code(SecurityDomain securityDomain);
/** Setter for security domain code */
const int ftress_security_domain_set_code(SecurityDomain securityDomain, char *domainCode);
/**Free the security domain */
const int ftress_security_domain_free(SecurityDomain securityDomain);
/*************************************************************************************
* AuthenticationRequestParameter *
*************************************************************************************/
/**Default constructor for Authentication Request Parameter */
AuthenticationRequestParameter ftress_up_authentication_request_parameter_create_default();
/** Parameterised constructor for Authentication Request Parameter*/
AuthenticationRequestParameter ftress_up_authentication_request_parameter_create(char *name, char *value);
/** Setter for up authentication request parameter name*/
const int ftress_up_authentication_request_parameter_set_name(AuthenticationRequestParameter authenticationRequestParameter, char *name);
/** Getter for up authentication request parameter name */
char * ftress_up_authentication_request_parameter_get_name(AuthenticationRequestParameter authenticationRequestParameter);
/** Setter for up authentication request parameter value */
const int ftress_up_authentication_request_parameter_set_value(AuthenticationRequestParameter authenticationRequestParameter, char *value);
/** Getter for up authentication request parameter value */
char * ftress_up_authentication_request_parameter_get_value(AuthenticationRequestParameter authenticationRequestParameter);
/**Free the authentication request parameter */
const int ftress_authentication_request_parameter_free(AuthenticationRequestParameter authenticationRequestParameter);
/*************************************************************************************
* AuthenticationTypeCode *
*************************************************************************************/
/** Default constructor for Authentication Type Code*/
AuthenticationTypeCode ftress_authentication_type_code_create_default();
/** Parameterised constructor for Authentication Type Code */
AuthenticationTypeCode ftress_authentication_type_code_create(char *code);
/** Setter for Authentication Type Code */
const int ftress_authentication_type_code_set_code(AuthenticationTypeCode authenticationTypeCode, char *code);
/** Getter for Authentication Type Code */
char* ftress_authentication_type_code_get_code(AuthenticationTypeCode authenticationTypeCode);
/**Free the Authentication Type Code */
const int ftress_authentication_type_code_free(AuthenticationTypeCode authenticationTypeCode);
/*************************************************************************************
* UserCode *
*************************************************************************************/
/** Default constructor for User Code */
UserCode ftress_user_code_create_default();
/** Copy constructor for User Code */
UserCode ftress_user_code_copy(UserCode userCode);
/** Parameterised constructor for User Code */
UserCode ftress_user_code_create(char *code);
/** Setter for User Code */
const int ftress_user_code_set_code(UserCode userCode, char *code);
/** Getter for User Code */
char * ftress_user_code_get_code(UserCode userCode);
/**Free the User Code */
const int ftress_user_code_free(UserCode userCode);
/*************************************************************************************
* ArrayOfAuthenticationRequestParameter *
*************************************************************************************/
/** Create array of authentication request parameter */
ArrayOfAuthenticationRequestParameter ftress_arrayof_authentication_request_parameter_create(int size, AuthenticationRequestParameter *authenticationRequestParameter);
/** Getter for array size of ArrayOfAuthenticationRequestParameter */
int ftress_arrayof_authentication_request_parameter_get_size(ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter);
/** Getter for array of authenticationRequestParameter */
AuthenticationRequestParameter * ftress_arrayof_authentication_request_parameter_get_parameters(ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter);
/** Setter for array size of ArrayOfAuthenticationRequestParameter */
const int ftress_arrayof_authentication_request_parameter_set_size(ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter, int size);
/** Setter for array of authenticationRequestParameter */
const int ftress_arrayof_authentication_request_parameter_set_parameters(ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter, AuthenticationRequestParameter *authenticationRequestParameter);
/** Free the ArrayOfAuthenticationRequestParameter */
const int ftress_arrayof_authentication_request_parameter_free(ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter);
/*************************************************************************************
* ArrayOfInt *
*************************************************************************************/
/** Create array of int */
ArrayOfInt ftress_arrayof_int_create(int size, int *values);
/** Getter for array size of ArrayOfInt */
int ftress_arrayof_int_get_size(ArrayOfInt arrayOfInt);
/** Getter for array of int */
int * ftress_arrayof_int_get_positions(ArrayOfInt arrayOfInt);
/** Setter for array size of ArrayOfInt */
const int ftress_arrayof_int_set_size(ArrayOfInt arrayOfInt, int size);
/** Setter for array of int */
const int ftress_arrayof_int_set_positions(ArrayOfInt arrayOfInt, int *values);
/** Free the ArrayOfInt */
const int ftress_arrayof_int_free(ArrayOfInt arrayOfInt);
/*************************************************************************************
* UPAuthenticationRequest *
*************************************************************************************/
/** Default constructor for up authentication request */
UPAuthenticationRequest ftress_up_authentication_request_create_default();
/** Parameterised constructor for UP Authentication Request */
UPAuthenticationRequest ftress_up_authentication_request_create(ArrayOfAuthenticationRequestParameter auditedParameters,
int authenticateNoSession,
AuthenticationTypeCode authenticationTypeCode,
ArrayOfAuthenticationRequestParameter parameters,
char *password,
ArrayOfInt seedPositions,
UserCode userCode,
char *username );
/** Returns the password. */
char * ftress_up_authentication_request_get_password(UPAuthenticationRequest upAuthenticationRequest);
/** Returns the seed positions. */
int * ftress_up_authentication_request_get_seed_positions(UPAuthenticationRequest upAuthenticationRequest);
/** Returns the user code (external reference) of a specific user. */
UserCode ftress_up_authentication_request_get_user_code(UPAuthenticationRequest upAuthenticationRequest);
/** Returns the user name. */
char * ftress_up_authentication_request_get_user_name(UPAuthenticationRequest upAuthenticationRequest);
/** Returns the authentication type (code) of the authentication. */
AuthenticationTypeCode ftress_up_authentication_request_get_authentication_type_code(UPAuthenticationRequest upAuthenticationRequest);
/**Returns the audited parameters. */
ArrayOfAuthenticationRequestParameter ftress_up_authentication_request_get_audited_parameters(UPAuthenticationRequest upAuthenticationRequest);
/**Returns the parameters. */
ArrayOfAuthenticationRequestParameter ftress_up_authentication_request_get_parameters(UPAuthenticationRequest upAuthenticationRequest);
/** Returns true/false ie 1/0 based on authenticate session */
int ftress_up_authentication_request_get_authenticate_no_session(UPAuthenticationRequest upAuthenticationRequest);
/** Sets the password (see note about seeded authentication above). */
const int ftress_up_authentication_request_set_password(UPAuthenticationRequest upAuthenticationRequest, char *password);
/** Sets the seed positions (of the seeded password). */
const int ftress_up_authentication_request_set_seed_positions(UPAuthenticationRequest upAuthenticationRequest, int *seedPositions);
/**Sets the user code (external reference) of a specific user. */
const int ftress_up_authentication_request_set_user_code(UPAuthenticationRequest upAuthenticationRequest, UserCode userCode);
/** Sets the user name (which in combination with the authentication type, identifies the user). */
const int ftress_up_authentication_request_set_user_name(UPAuthenticationRequest upAuthenticationRequest, char *userName);
/** Sets the authentication type (code) of the authentication. */
const int ftress_up_authentication_request_set_authentication_type_code(UPAuthenticationRequest upAuthenticationRequest, AuthenticationTypeCode authenticationTypeCode);
/**Sets the audited parameters. */
const int ftress_up_authentication_request_set_audited_parameters(UPAuthenticationRequest upAuthenticationRequest, ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter);
/**Sets the parameters. */
const int ftress_up_authentication_request_set_parameters(UPAuthenticationRequest upAuthenticationRequest, ArrayOfAuthenticationRequestParameter arrayOfAuthenticationRequestParameter);
/** Sets true/false ie 1/0 based on authenticate session */
const int ftress_up_authentication_request_set_authenticate_no_session(UPAuthenticationRequest upAuthenticationRequest, int authenticateNoSession);
/**Free the UP Authentication Request */
const int ftress_up_authentication_request_free(UPAuthenticationRequest upAuthenticationRequest);
/*************************************************************************************
* Alsi *
*************************************************************************************/
/**Default constructor for Alsi */
Alsi ftress_alsi_create_default();
/** Copy constructor for Alsi */
Alsi ftress_alsi_copy(Alsi alsi);
/** Parameterised constructor for Alsi */
Alsi ftress_alsi_create(char *alsi);
/** Getter for Alsi */
char * ftress_alsi_get_alsi(Alsi alsi);
/** Getter for Alsi time stamp */
time_t * ftress_alsi_get_time_stamp(Alsi alsi);
/** Setter for Alsi */
const int ftress_alsi_set_alsi(Alsi alsi, char *ALSI);
/** Setter for Alsi time stamp*/
const int ftress_alsi_set_time_stamp(Alsi alsi, time_t *time);
/**Free the Alsi */
const int ftress_alsi_free(Alsi alsi);
/*************************************************************************************
* AuthenticationStatistics *
*************************************************************************************/
/** Constructor for AuthenticationStatistics */
AuthenticationStatistics ftress_authentication_statistics_create();
/**Getter for authentication statistics challenge count. Return the challenge counter */
int * ftress_authentication_statistics_get_challenge_count(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics consecutive failed. Returns the count of consecutive, failed authentication attempts. */
int ftress_authentication_statistics_get_consecutive_failed(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics consecutive success. Returns the count of successful authentication attempts since the password was first set, reset or modified. */
int ftress_authentication_statistics_get_consecutive_success(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics last successful channel. Returns the channel (code) of the last successful authentication attempt. */
ChannelCode ftress_authentication_statistics_get_last_successful_channel(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics last successful date time. Returns the datetime of the last successful authentication attempt. */
time_t * ftress_authentication_statistics_get_last_successful_date_time(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics last unsuccessful channel. Returns the channel (code) of the last unsuccessful authentication attempt. */
ChannelCode ftress_authentication_statistics_get_last_unsuccessful_channel(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics last unsuccessful date time. Returns the datetime of the last unsuccessful authentication attempt. */
time_t * ftress_authentication_statistics_get_last_unsuccessful_date_time(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics total count of authentication attempts. Returns the total count of authentication attempts. */
int ftress_authentication_statistics_get_total(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics total count of failed authentications. */
int ftress_authentication_statistics_get_total_failed(AuthenticationStatistics authenticationStatistics);
/** Getter for authentication statistics total count of successful authentications. */
int ftress_authentication_statistics_get_total_successful(AuthenticationStatistics authenticationStatistics);
/** Setters for authentication statistics */
/** Setter for authentication statistics challenge count. Sets the challenge counter */
const int ftress_authentication_statistics_set_challenge_count(AuthenticationStatistics authenticationStatistics, int *challengeCount);
/** Setter for authentication statistics consecutive failed. Sets the count of consecutive, failed authentication attempts. */
const int ftress_authentication_statistics_set_consecutive_failed(AuthenticationStatistics authenticationStatistics, int consecutiveFailed);
/** Setter for authentication statistics consecutive success. Sets the count of successful authentication attempts since the password was first set, reset or modified. */
const int ftress_authentication_statistics_set_consecutive_success(AuthenticationStatistics authenticationStatistics, int consecutiveSuccess);
/** Setter for authentication statistics last successful channel. Sets the channel (code) of the last successful authentication attempt. */
const int ftress_authentication_statistics_set_last_successful_channel(AuthenticationStatistics authenticationStatistics, ChannelCode channelCode);
/** Setter for authentication statistics last successful date time. Sets the datetime of the last successful authentication attempt. */
const int ftress_authentication_statistics_set_last_successful_date_time(AuthenticationStatistics authenticationStatistics, time_t *lastSuccessfulDateTime);
/** Setter for authentication statistics last unsuccessful channel. Sets the channel (code) of the last unsuccessful authentication attempt. */
const int ftress_authentication_statistics_set_last_unsuccessful_channel(AuthenticationStatistics authenticationStatistics, ChannelCode channelCode);
/** Setter for authentication statistics last unsuccessful date time. Sets the datetime of the last unsuccessful authentication attempt. */
const int ftress_authentication_statistics_set_last_unsuccessful_date_time(AuthenticationStatistics authenticationStatistics, time_t *lastUnsuccessfulDateTime);
/** Setter for authentication statistics total count of authentication attempts. Sets the total count of authentication attempts.
*/
const int ftress_authentication_statistics_set_total(AuthenticationStatistics authenticationStatistics, int total);
/** Setter for authentication statistics total count of failed authentications. Sets the total count of failed authentication attempts. */
const int ftress_authentication_statistics_set_total_failed(AuthenticationStatistics authenticationStatistics, int totalFailed);
/** Setter for authentication statistics total count of successful authentications. Sets the total count of successful authentications. */
const int ftress_authentication_statistics_set_total_successful(AuthenticationStatistics authenticationStatistics, int totalSuccessful);
/**Free the authentication statistics */
const int ftress_authentication_statistics_free(AuthenticationStatistics authenticationStatistics);
/*************************************************************************************
* ArrayOfMDPromptCode *
*************************************************************************************/
/** Create array of MDPromptCode */
ArrayOfMDPromptCode ftress_arrayof_md_prompt_code_create(int size, MDPromptCode *mdPromptCode);
/** Getter for array size of MDPromptCode */
int ftress_arrayof_md_prompt_code_get_size(ArrayOfMDPromptCode arrayOfMDPromptCode);
/** Getter for array of MDPromptCode */
MDPromptCode * ftress_arrayof_md_prompt_code_get_prompts(ArrayOfMDPromptCode arrayOfMDPromptCode);
/** Setter for array size of MDPromptCode */
const int ftress_arrayof_md_prompt_code_set_size(ArrayOfMDPromptCode arrayOfMDPromptCode, int size);
/** Setter for array of MDPromptCode */
const int ftress_arrayof_md_prompt_code_set_prompts(ArrayOfMDPromptCode arrayOfMDPromptCode, MDPromptCode *mdPromptCode);
// Free
/**
* Free the ArrayOfMDPromptCode
*/
const int ftress_arrayof_md_prompt_code_free(ArrayOfMDPromptCode arrayOfMDPromptCode);
/*************************************************************************************
* MDPromptCode *
*************************************************************************************/
/** Constructor for MDPromptCode */
MDPromptCode ftress_md_prompt_code_create_default();
/** Parameterised constructor for MDPromptCode */
MDPromptCode ftress_md_prompt_code_create(char *code);
/** Getter for MDPromptCode. Returns the string representing the code.*/
char * ftress_md_prompt_code_get_code(MDPromptCode mdPromptCode);
/** Setter for MDPromptCode. Sets the string representing the code. */
const int ftress_md_prompt_code_set_code(MDPromptCode mdPromptCode, char *code);
/**Free the MDPromptCode */
const int ftress_md_prompt_code_free(MDPromptCode mdPromptCode);
/*************************************************************************************
* AuthenticationResponseParameter *
*************************************************************************************/
/** Constructor for AuthenticationResponseParameter */
AuthenticationResponseParameter ftress_authentication_response_parameter_create_default();
/** Parameterised constructor for AuthenticationResponseParameter */
AuthenticationResponseParameter ftress_authentication_response_parameter_create(char *name, char *value);
/** Getter for Authentication Response Parameter name */
char * ftress_authentication_response_parameter_get_name(AuthenticationResponseParameter authenticationResponseParameter);
/** Getter for Authentication Response Parameter value */
char * ftress_authentication_response_parameter_get_value(AuthenticationResponseParameter authenticationResponseParameter);
/** Setter for Authentication Response Parameter name */
const int ftress_authentication_response_parameter_set_name(AuthenticationResponseParameter authenticationResponseParameter, char *name);
/** Setter for Authentication Response Parameter value */
const int ftress_authentication_response_parameter_set_value(AuthenticationResponseParameter authenticationResponseParameter, char *value);
/**Free the Authentication Response Parameter */
const int ftress_authentication_response_parameter_free(AuthenticationResponseParameter authenticationResponseParameter);
/*************************************************************************************
* AuthenticationResponse *
*************************************************************************************/
/** Constructor for Authentication Response */
AuthenticationResponse ftress_authentication_response_create();
/** Getter for authentication response ALSI */
Alsi ftress_authentication_response_get_alsi(AuthenticationResponse authenticationResponse);
/** Getter for authentication response expiryThreshold */
int ftress_authentication_response_get_expiry_threshold(AuthenticationResponse authenticationResponse);
/** Getter for authentication response message */
char * ftress_authentication_response_get_message(AuthenticationResponse authenticationResponse);
/** Getter for authentication response reason */
int ftress_authentication_response_get_reason(AuthenticationResponse authenticationResponse);
/** Getter for authentication response response */
int ftress_authentication_response_get_response(AuthenticationResponse authenticationResponse);
/** Getter for authentication response */
char * ftress_authentication_response_get_status(AuthenticationResponse authenticationResponse);
/** Getter for authentication response user code*/
UserCode ftress_authentication_response_get_user_code(AuthenticationResponse authenticationResponse);
/** Getter for authentication response authentication statistics */
AuthenticationStatistics ftress_authentication_response_get_authentication_statistics(AuthenticationResponse authenticationResponse);
/** Getter for authentication response array of MDPromptCode. Returns the failed MD prompts (MD authentication only). */
MDPromptCode * ftress_authentication_response_get_arrayof_md_prompt_code(AuthenticationResponse authenticationResponse);
/** Getter for authentication response array of AuthenticationResponseParameter. Returns the parameters */
AuthenticationResponseParameter * ftress_authentication_response_get_parameters(AuthenticationResponse authenticationResponse);
/** Setter for authentication response ALSI */
const int ftress_authentication_response_set_alsi(AuthenticationResponse authenticationResponse, Alsi alsi);
/** Setter for authentication response expiryThreshold */
const int ftress_authentication_response_set_expiry_threshold(AuthenticationResponse authenticationResponse, int expiryThreshold);
/** Setter for authentication response message */
const int ftress_authentication_response_set_message(AuthenticationResponse authenticationResponse, char *message);
/** Setter for authentication response reason */
const int ftress_authentication_response_set_reason(AuthenticationResponse authenticationResponse, int reason);
/** Setter for authentication response response */
const int ftress_authentication_response_set_response(AuthenticationResponse authenticationResponse, int response);
/** Setter for authentication response */
const int ftress_authentication_response_set_status(AuthenticationResponse authenticationResponse, char *status);
/** Setter for authentication response user code*/
const int ftress_authentication_response_set_user_code(AuthenticationResponse authenticationResponse, UserCode userCode);
/** Setter for authentication response authentication statistics */
const int ftress_authentication_response_set_authentication_statistics(AuthenticationResponse authenticationResponse, AuthenticationStatistics authenticationStatistics);
/** Setter for authentication response array of MDPromptCode. Returns the failed MD prompts (MD authentication only). */
const int ftress_authentication_response_set_array_of_md_prompt_code(AuthenticationResponse authenticationResponse, MDPromptCode *mdPromptCode);
/** Setter for authentication response array of AuthenticationResponseParameter. Returns the parameters */
const int ftress_authentication_response_set_parameters(AuthenticationResponse authenticationResponse, AuthenticationResponseParameter *authenticationResponseParameter);
/**Free the Authentication Response */
const int ftress_authentication_response_free(AuthenticationResponse authenticationResponse);
/************************************************************************************
* DateRangeSearchCriteria *
************************************************************************************/
/** Constructs a new DateRangeSearchCriteria */
DateRangeSearchCriteria ftress_date_range_search_criteria_create();
// Getters
/** gets the exact date in case there are no range of dates */
time_t * ftress_date_range_search_criteria_get_date_equals(DateRangeSearchCriteria dateRangeSearchCriteria);
/** gets the from date. */
time_t * ftress_date_range_search_criteria_get_date_from(DateRangeSearchCriteria dateRangeSearchCriteria);
/** gets the to date */
time_t * ftress_date_range_search_criteria_get_date_to(DateRangeSearchCriteria dateRangeSearchCriteria);
// Setters
/** sets the exact date in case there are no range of dates */
const int ftress_date_range_search_criteria_set_date_equals(DateRangeSearchCriteria dateRangeSearchCriteria,
time_t *dateEquals);
/** sets the from date. */
const int ftress_date_range_search_criteria_set_date_from(DateRangeSearchCriteria dateRangeSearchCriteria,
time_t *dateFrom);
/** sets the to date */
const int ftress_date_range_search_criteria_set_date_to(DateRangeSearchCriteria dateRangeSearchCriteria,
time_t * dateTo);
// Free
/** Free the DateRangeSearchCriteria */
const int ftress_date_range_search_criteria_free(DateRangeSearchCriteria dateRangeSearchCriteria);
/************************************************************************************
* DeviceAuthenticationRequest *
************************************************************************************/
/** Default Constructor for DeviceAuthenticationRequest */
DeviceAuthenticationRequest ftress_device_authentication_request_create_default();
/** Parameterised Constructor for DeviceAuthenticationRequest */
DeviceAuthenticationRequest ftress_device_authentication_request_create(ArrayOfAuthenticationRequestParameter auditedParameters,
int authenticateNoSession,
AuthenticationTypeCode authenticationTypeCode,
ArrayOfAuthenticationRequestParameter parameters,
int authenticationMode,
char *challenge,
DeviceSearchCriteria deviceCriteria,
char *oneTimePassword,
UserCode userCode);
/** Getters */
/** Returns the audited parameters. */
ArrayOfAuthenticationRequestParameter ftress_device_authentication_request_get_audited_parameters(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the non-audited parameters. */
ArrayOfAuthenticationRequestParameter ftress_device_authentication_request_get_parameters(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns true/false based on authenticate session */
int ftress_device_authentication_request_get_authenticate_no_session(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the authentication type (code) of the authentication. */
AuthenticationTypeCode ftress_device_authentication_request_get_authentication_type_code(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the authentication mode of this request either SYNC/ASYNC */
int ftress_device_authentication_request_get_authentication_mode(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the user defined challenge for this request */
char * ftress_device_authentication_request_get_challenge(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the device search criteria for this request */
DeviceSearchCriteria ftress_device_authentication_request_get_device_criteria(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the one time oneTimePassword for this authentication request */
char * ftress_device_authentication_request_get_one_time_password(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Returns the user code. */
UserCode ftress_device_authentication_request_get_user_code(DeviceAuthenticationRequest deviceAuthenticationRequest);
/** Setters */
/** Sets the audited parameters. */
const int ftress_device_authentication_request_set_audited_parameters(DeviceAuthenticationRequest deviceAuthenticationRequest, ArrayOfAuthenticationRequestParameter auditedParameters);
/** Sets the non-audited parameters. */
const int ftress_device_authentication_request_set_parameters(DeviceAuthenticationRequest deviceAuthenticationRequest, ArrayOfAuthenticationRequestParameter parameter);
/** Sets true/false based on authenticate session */
const int ftress_device_authentication_request_set_authenticate_no_session(DeviceAuthenticationRequest deviceAuthenticationRequest, int authenticateNoSession);
/** Sets the authentication type (code) of the authentication. */
const int ftress_device_authentication_request_set_authentication_type_code(DeviceAuthenticationRequest deviceAuthenticationRequest, AuthenticationTypeCode authenticationTypeCode);
/** Sets the authentication mode of this request either SYNC/ASYNC */
const int ftress_device_authentication_request_set_authentication_mode(DeviceAuthenticationRequest deviceAuthenticationRequest, int authenticationMode);
/** Sets the user defined challenge for this request */
const int ftress_device_authentication_request_set_challenge(DeviceAuthenticationRequest deviceAuthenticationRequest, char *challenge);
/** Sets the device search criteria for this request */
const int ftress_device_authentication_request_set_device_criteria(DeviceAuthenticationRequest deviceAuthenticationRequest, DeviceSearchCriteria deviceSearchCriteria);
/** Sets the one time oneTimePassword for this authentication request */
const int ftress_device_authentication_request_set_one_time_password(DeviceAuthenticationRequest deviceAuthenticationRequest, char *oneTimePassword);
/** Sets the user code. */
const int ftress_device_authentication_request_set_user_code(DeviceAuthenticationRequest deviceAuthenticationRequest, UserCode userCode);
// Free
/** Ftree the DeviceAuthenticationRequest */
const int ftress_device_authentication_request_free(DeviceAuthenticationRequest deviceAuthenticationRequest);
/************************************************************************************
* SeedPositions *
************************************************************************************/
/** Constructs a new SeedPositions. */
SeedPositions ftress_seed_positions_create_default();
/** Constructs a new SeedPositions with the specified positions. */
SeedPositions ftress_seed_positions_create(ArrayOfInt arrayOfInt);
// Getters
/** Returns the positions of character(s) in a password. */
ArrayOfInt ftress_seed_positions_get_positions(SeedPositions seedPositions);
// Setters
/** Sets the positions of character(s) in a password. */
const int ftress_seed_positions_set_positions(SeedPositions seedPositions, ArrayOfInt arrayOfInt);
// Free
/** Free the seed positions */
const int ftress_seed_positions_free(SeedPositions seedPositions);
/************************************************************************************
* MDAuthenticationRequest *
************************************************************************************/
/**
* Constructs a new MDAuthenticationRequest.
*/
MDAuthenticationRequest ftress_md_authentication_request_create_default();
/**
* Constructs a new MDAuthenticationRequest.
*/
MDAuthenticationRequest ftress_md_authentication_request_create(ArrayOfAuthenticationRequestParameter auditedParameters,
int authenticateNoSession,
AuthenticationTypeCode authenticationTypeCode,
ArrayOfAuthenticationRequestParameter parameters,
ArrayOfMDAuthenticationAnswer answers,
UserCode userCode);
// Getters
/**
* Returns the audited parameters.
*/
ArrayOfAuthenticationRequestParameter ftress_md_authentication_request_get_audited_parameters(MDAuthenticationRequest mdAuthenticationRequest);
/**
* Returns true/false based on authenticate session
*/
int ftress_md_authentication_request_get_authenticate_no_session(MDAuthenticationRequest mdAuthenticationRequest);
/**
* Returns the authentication type (code) of the authentication.
*/
AuthenticationTypeCode ftress_md_authentication_request_get_authentication_type_code(MDAuthenticationRequest mdAuthenticationRequest);
/**
* Returns the non-audited parameters.
*/
ArrayOfAuthenticationRequestParameter ftress_md_authentication_request_get_parameters(MDAuthenticationRequest mdAuthenticationRequest);
/**
* Returns the answers provided to authenticate the user.
*/
ArrayOfMDAuthenticationAnswer ftress_md_authentication_request_get_answers(MDAuthenticationRequest mdAuthenticationRequest);
/**
* Returns the unique user code (external reference).
*/
UserCode ftress_md_authentication_request_get_user_code(MDAuthenticationRequest mdAuthenticationRequest);
// Setters
/**
* Sets the audited parameters.
*/
const int ftress_md_authentication_request_set_audited_parameters(MDAuthenticationRequest mdAuthenticationRequest,
ArrayOfAuthenticationRequestParameter auditedParameters);
/**
* Sets true/false based on authenticate session
*/
const int ftress_md_authentication_request_set_authenticate_no_session(MDAuthenticationRequest mdAuthenticationRequest,
int authenticateNoSession);
/**
* Sets the authentication type (code) of the authentication.
*/
const int ftress_md_authentication_request_set_authentication_type_code(MDAuthenticationRequest mdAuthenticationRequest,
AuthenticationTypeCode authenticationTypeCode);
/**
* Sets the non-audited parameters.
*/
const int ftress_md_authentication_request_set_parameters(MDAuthenticationRequest mdAuthenticationRequest,
ArrayOfAuthenticationRequestParameter parameters);
/**
* Sets the answers provided to authenticate the user.
*/
const int ftress_md_authentication_request_set_answers(MDAuthenticationRequest mdAuthenticationRequest, ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer);
/**
* Sets the unique user code (external reference).
*/
const int ftress_md_authentication_request_set_user_code(MDAuthenticationRequest mdAuthenticationRequest,
UserCode userCode);
// Free
/**
* Free the MDAuthenticationRequest
*/
const int ftress_md_authentication_request_free(MDAuthenticationRequest mdAuthenticationRequest);
/************************************************************************************
* ArrayOfMDAuthenticationAnswer *
************************************************************************************/
/**
* Constructs a new ArrayOfMDAuthenticationAnswer
*/
ArrayOfMDAuthenticationAnswer ftress_arrayof_md_authentication_answer_create(int size, MDAuthenticationAnswer *mdAuthenticationAnswer);
// Getters
/**
* Returns size of ArrayOfMDAuthenticationAnswer
*/
int ftress_arrayof_md_authentication_answer_get_size(ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer);
/**
* Returns array of MDAuthenticationAnswer.
*/
MDAuthenticationAnswer * ftress_arrayof_md_authentication_answer_get_md_authentication_answer(ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer);
// Setters
/**
* Sets size of ArrayOfMDAuthenticationAnswer
*/
const int ftress_arrayof_md_authentication_answer_set_size(ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer,
int size);
/**
* Sets array of MDAuthenticationAnswer.
*/
const int ftress_arrayof_md_authentication_answer_set_md_authentication_answer(ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer,
MDAuthenticationAnswer *mdAuthenticationAnswer);
// Free
/**
* Free the ArrayOfMDAuthenticationAnswer
*/
const int ftress_arrayof_md_authentication_answer_free(ArrayOfMDAuthenticationAnswer arrayOfMDAuthenticationAnswer);
/************************************************************************************
* MDAuthenticationAnswer *
************************************************************************************/
/**
* Constructs a new MDAuthenticationAnswer.
*/
MDAuthenticationAnswer ftress_md_authentication_answer_create_default();
/**
* Constructs a new MDAuthenticationAnswer with specified answer and prompt code.
*/
MDAuthenticationAnswer ftress_md_authentication_answer_create(char *answer,
MDPromptCode mdPromptCode);
/**
* Constructs a new MDAuthenticationAnswer with specified answer, prompt code and seed positions.
*/
MDAuthenticationAnswer ftress_md_authentication_answer_create_for_seeded_auth(char *answer,
MDPromptCode mdPromptCode,
ArrayOfInt arrayOfInt);
// Getters
/**
* Returns the answer.
*/
char * ftress_md_authentication_answer_get_answer(MDAuthenticationAnswer mdAuthenticationAnswer);
/**
* Returns the memorable data prompt (code).
*/
MDPromptCode ftress_md_authentication_answer_get_md_prompt_code(MDAuthenticationAnswer mdAuthenticationAnswer);
/**
* Returns the seed positions (positions i.e. indexes, of characters in the answer) (optional).
*/
ArrayOfInt ftress_md_authentication_answer_get_seed_positions(MDAuthenticationAnswer mdAuthenticationAnswer);
/**
* Sets the answer.
*/
const int ftress_md_authentication_answer_set_answer(MDAuthenticationAnswer mdAuthenticationAnswer,
char *answer);
/**
* Sets the memorable data prompt (code).
*/
const int ftress_md_authentication_answer_set_md_prompt_code(MDAuthenticationAnswer mdAuthenticationAnswer,
MDPromptCode mdPromptCode);
/**
* Sets the seed positions (positions i.e. indexes, of characters in the answer) (optional).
*/
const int ftress_md_authentication_answer_set_seed_positions(MDAuthenticationAnswer mdAuthenticationAnswer,
ArrayOfInt arrayOfInt);
// Free
/**
* Free the MDAuthenticationAnswer
*/
const int ftress_md_authentication_answer_free(MDAuthenticationAnswer mdAuthenticationAnswer);
/************************************************************************************
* MDPromptCode *
************************************************************************************/
/**
* Constructs a new MDPromptCode.
*/
MDPromptCode ftress_md_prompt_code_create_default();
/**
* Constructs a new MDPromptCode with the specified code.
*/
MDPromptCode ftress_md_prompt_code_create(char *code);
//Getters
/**
* Returns the string representing the code.
*/
char * ftress_md_prompt_code_get_code(MDPromptCode mdPromptCode);
// Setters
/**
* Sets the string representing the code.
*/
const int ftress_md_prompt_code_set_code(MDPromptCode mdPromptCode, char *code);
// Free
/**
* Free the MDPromptCode.
*/
const int ftress_md_prompt_code_free(MDPromptCode mdPromptCode);
/************************************************************************************
* MDAuthenticationPrompts *
************************************************************************************/
/**
* Constructs a new MDAuthenticationPrompts.
*/
MDAuthenticationPrompts ftress_md_authentication_prompts_create();
// Getters
/**
* Returns the number of MD answers that are required to authenticate.
*/
int ftress_md_authentication_prompts_get_answers_required(MDAuthenticationPrompts mdAuthenticationPrompts);
/**
* Returns the available MD prompts to which answers can be provided.
*/
ArrayOfMDAuthenticationPrompt ftress_md_authentication_prompts_get_prompts(MDAuthenticationPrompts mdAuthenticationPrompts);
// Setters
/**
* Sets the number of MD answers that are required to authenticate.
*/
const int ftress_md_authentication_prompts_set_answers_required(MDAuthenticationPrompts mdAuthenticationPrompts,
int answersRequired);
/**
* Sets the available MD prompts to which answers can be provided.
*/
const int ftress_md_authentication_prompts_set_prompts(MDAuthenticationPrompts mdAuthenticationPrompts,
ArrayOfMDAuthenticationPrompt prompts);
// Free
/**
* Free the MDAuthenticationPrompts
*/
const int ftress_md_authentication_prompts_free(MDAuthenticationPrompts mdAuthenticationPrompts);
/************************************************************************************
* ArrayOfMDAuthenticationPrompt *
************************************************************************************/
/**
* Constructs a new ArrayOfMDAuthenticationPrompt
*/
ArrayOfMDAuthenticationPrompt ftress_arrayof_md_authentication_prompt_create(int size,
MDAuthenticationPrompt *mdAuthenticationPrompt);
// Getters
/**
* Returns the size of ArrayOfMDAuthenticationPrompt
*/
int ftress_arrayof_md_authentication_prompt_get_size(ArrayOfMDAuthenticationPrompt prompts);
/**
* Returns the array of MDAuthenticationPrompt
*/
MDAuthenticationPrompt * ftress_arrayof_md_authentication_prompt_get_prompts(ArrayOfMDAuthenticationPrompt prompts);
// Setters
/**
* Sets the size of ArrayOfMDAuthenticationPrompt