CryptoKeySecurity.cs 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. //
  2. // System.Security.AccessControl.CryptoKeySecurity implementation
  3. //
  4. // Authors:
  5. // Sebastien Pouliot <[email protected]>
  6. // Dick Porter <[email protected]>
  7. // Atsushi Enomoto <[email protected]>
  8. //
  9. // Copyright (C) 2005-2007 Novell, Inc (http://www.novell.com)
  10. //
  11. // Permission is hereby granted, free of charge, to any person obtaining
  12. // a copy of this software and associated documentation files (the
  13. // "Software"), to deal in the Software without restriction, including
  14. // without limitation the rights to use, copy, modify, merge, publish,
  15. // distribute, sublicense, and/or sell copies of the Software, and to
  16. // permit persons to whom the Software is furnished to do so, subject to
  17. // the following conditions:
  18. //
  19. // The above copyright notice and this permission notice shall be
  20. // included in all copies or substantial portions of the Software.
  21. //
  22. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  23. // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  24. // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  25. // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
  26. // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
  27. // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  28. // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  29. //
  30. using System.Security.Principal;
  31. namespace System.Security.AccessControl
  32. {
  33. public sealed class CryptoKeySecurity : NativeObjectSecurity
  34. {
  35. // CommonSecurityDescriptor securityDescriptor;
  36. [MonoTODO]
  37. public CryptoKeySecurity ()
  38. {
  39. }
  40. [MonoTODO]
  41. public CryptoKeySecurity (CommonSecurityDescriptor securityDescriptor)
  42. {
  43. // this.securityDescriptor = securityDescriptor;
  44. }
  45. public override Type AccessRightType {
  46. get { return typeof (CryptoKeyRights); }
  47. }
  48. public override Type AccessRuleType {
  49. get { return typeof (CryptoKeyAccessRule); }
  50. }
  51. public override Type AuditRuleType {
  52. get { return typeof (CryptoKeyAuditRule); }
  53. }
  54. // AccessRule
  55. public override sealed AccessRule AccessRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AccessControlType type)
  56. {
  57. return new CryptoKeyAccessRule (identityReference, (CryptoKeyRights) accessMask, type);
  58. }
  59. [MonoTODO]
  60. public void AddAccessRule (CryptoKeyAccessRule rule)
  61. {
  62. throw new NotImplementedException ();
  63. }
  64. [MonoTODO]
  65. public bool RemoveAccessRule (CryptoKeyAccessRule rule)
  66. {
  67. throw new NotImplementedException ();
  68. }
  69. [MonoTODO]
  70. public void RemoveAccessRuleAll (CryptoKeyAccessRule rule)
  71. {
  72. throw new NotImplementedException ();
  73. }
  74. [MonoTODO]
  75. public void RemoveAccessRuleSpecific (CryptoKeyAccessRule rule)
  76. {
  77. throw new NotImplementedException ();
  78. }
  79. [MonoTODO]
  80. public void ResetAccessRule (CryptoKeyAccessRule rule)
  81. {
  82. throw new NotImplementedException ();
  83. }
  84. [MonoTODO]
  85. public void SetAccessRule (CryptoKeyAccessRule rule)
  86. {
  87. throw new NotImplementedException ();
  88. }
  89. // AuditRule
  90. public override sealed AuditRule AuditRuleFactory (IdentityReference identityReference, int accessMask, bool isInherited, InheritanceFlags inheritanceFlags, PropagationFlags propagationFlags, AuditFlags flags)
  91. {
  92. return new CryptoKeyAuditRule (identityReference, (CryptoKeyRights) accessMask, flags);
  93. }
  94. [MonoTODO]
  95. public void AddAuditRule (CryptoKeyAuditRule rule)
  96. {
  97. throw new NotImplementedException ();
  98. }
  99. [MonoTODO]
  100. public bool RemoveAuditRule (CryptoKeyAuditRule rule)
  101. {
  102. throw new NotImplementedException ();
  103. }
  104. [MonoTODO]
  105. public void RemoveAuditRuleAll (CryptoKeyAuditRule rule)
  106. {
  107. throw new NotImplementedException ();
  108. }
  109. [MonoTODO]
  110. public void RemoveAuditRuleSpecific (CryptoKeyAuditRule rule)
  111. {
  112. throw new NotImplementedException ();
  113. }
  114. [MonoTODO]
  115. public void SetAuditRule (CryptoKeyAuditRule rule)
  116. {
  117. throw new NotImplementedException ();
  118. }
  119. }
  120. }