11.07.2015 Views

Improving Web Application Security: Threats and - CGISecurity

Improving Web Application Security: Threats and - CGISecurity

Improving Web Application Security: Threats and - CGISecurity

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 13: Building Secure Remoted Components 365Using a Custom Channel SinkYou could implement a custom channel sink to perform client-side <strong>and</strong>/or serversideexception logging. You can log exception details in the SyncProcessMessage,ProcessMessage, or SyncProcessMessage methods if an exception occurs. TheIMessage <strong>and</strong> Exception parameters provide exception details.Auditing <strong>and</strong> LoggingIf you use the ASP.NET host, you can use IIS auditing features. If you use a customhost, implement custom auditing. To do this, you could implement a custom channelsink.Using a Custom Channel SinkYou could implement a custom channel sink to perform client-side <strong>and</strong>/or serversideauditing. You can get details from the SyncProcessMessage, ProcessMessage,or SyncProcessMessage methods.Code Access <strong>Security</strong> (CAS) ConsiderationsSummaryRemoting clients require full trust on version 1.0 <strong>and</strong> 1.1 of the .NET Framework.The System.Runtime.Remoting.dll assembly is not marked withAllowPartiallyTrustedCallersAttribute.To use remoting to call a remote component from partial trust code such as a partialtrust <strong>Web</strong> application, you must create a full trust wrapper assembly <strong>and</strong> s<strong>and</strong>box theremote object method calls. For more information about s<strong>and</strong>boxing code <strong>and</strong> usingwrapper assemblies, see Chapter 9, “Using Code Access <strong>Security</strong> with ASP.NET.”The .NET Framework remoting infrastructure is designed for use in trusted serverscenarios where you can limit callers to trusted clients, for example by using IPSecsecurity policies. If you use an ASP.NET host <strong>and</strong> the HttpChannel, you benefit frombeing able to use the underlying security features provided by ASP.NET <strong>and</strong> IIS. Ifyou use a custom host <strong>and</strong> the TcpChannel, perhaps for performance reasons, youmust implement your own authentication <strong>and</strong> authorization solutions. IPSec can helpin these scenarios by providing machine level authentication <strong>and</strong> securecommunication.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!