File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,6 +37,28 @@ public static void ValidateNotNull(EncryptionParameters parameters)
3737 throw new ArgumentNullException ( nameof ( parameters . IV ) , "IV property cannot be null." ) ;
3838 }
3939 }
40+ public static void ValidateNotNull ( DecryptionParameters parameters )
41+ {
42+ if ( parameters == null )
43+ {
44+ throw new ArgumentNullException ( nameof ( parameters ) , "ByteEncryptionParameters instance cannot be null." ) ;
45+ }
46+
47+ if ( parameters . DataToDecrypt == null )
48+ {
49+ throw new ArgumentNullException ( nameof ( parameters . DataToDecrypt ) , "DataToDecrypt property cannot be null." ) ;
50+ }
51+
52+ if ( parameters . SecretKey == null )
53+ {
54+ throw new ArgumentNullException ( nameof ( parameters . SecretKey ) , "SecretKey property cannot be null." ) ;
55+ }
56+
57+ if ( parameters . IV == null )
58+ {
59+ throw new ArgumentNullException ( nameof ( parameters . IV ) , "IV property cannot be null." ) ;
60+ }
61+ }
4062
4163 public static void ValidateNotNull ( StringEncryptionParameters parameters )
4264 {
You can’t perform that action at this time.
0 commit comments