Expand Minimize

Do not define 'SmtpPermission' with 'Unrestricted=true'

The CAS Policy for System.Net.Mail.SmtpPermission with setting 'Unrestricted=true' is not allowed.

CheckId SPC020615
TypeName DoNotDefineUnrestrictedSMTPPermission
Severity CriticalWarning
Type PermissionSet

Remove permission 'SmtpPermission' with setting 'Unrestricted=true' or remove permission completely.
Bad Practice

<Solution xmlns="http://schemas.microsoft.com/sharepoint/">
      <PermissionSet class="NamedPermissionSet" version="1">
        <IPermission class="System.Net.Mail.SmtpPermission, System, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="True" />

Disclaimer: The views and opinions expressed in this documentation and in SPCAF do not necessarily reflect the opinions and recommendations of Microsoft or any member of Microsoft. SPCAF and RENCORE are registered trademarks of Rencore. All other trademarks, service marks, collective marks, copyrights, registered names, and marks used or cited by this documentation are the property of their respective owners.