Devesprit.ImageProcessor & Devesprit.ImageServer

This file contains security settings of the system and specifies how images should be loaded.

Devesprit.ImageServer is able to load images from different sources. You can create a new source specific to your needs implementing IImageService interface and specify the settings of your source in this file.

Available Image Services:

LocalFileImageService A service for loading images from the File system.
CloudImageService A generic cloud image for retrieving images where the remote location has been rewritten as a virtual path. Commonly seen in content management systems like Umbraco.
BarcodeImageService A Service for generating different types of Barcodes (For more information, Click here!)
RemoteImageService* A service for loading images from the Internet. It can download images from an external Host and send them to the user after processing them.

*To load images remotely and out of your server, you must enable RemoteImageService and add the list of authorized Hosts to the whitelist.


Security.Config File Path:

%Your Website Root Folder%\config\imageprocessor\Security.Config

The Contents of Security.Config:

Copy Code
<?xml version="1.0" encoding="utf-8"?>
      Demo: Adding a Url will send cors headers to that requesting Url.
            "*" acts as a universal selector.
      <add url=""/>
    <service name="LocalFileImageService" type="Devesprit.ImageServer.Services.LocalFileImageService,
    <!--Disable the LocalFileImageService and enable this one when using virtual paths. -->
    <!--<service name="CloudImageService" type="Devesprit.ImageServer.Services.CloudImageService,
        <setting key="MaxBytes" value="8194304"/>
        <setting key="Timeout" value="30000"/>
        <setting key="Host" value=""/>
    <service prefix="remote.axd" name="RemoteImageService"
            type="Devesprit.ImageServer.Services.RemoteImageService, Devesprit.ImageServer">
       <!-- The timeout for a request in milliseconds and the maximum
            allowable download in bytes. -->
        <setting key="MaxBytes" value="4194304"/>
        <setting key="Timeout" value="3000"/>
        <setting key="Protocol" value="http"/>
        <!-- Sets a user agent value for the request. Useful for social networks.
             See for available values. -->
        <setting key="Useragent" value=""/>
      <!-- Sets allowable domains to process images from. -->
        <add url=""/>
        <add url="" extensionLess="true" imageFormat=".png"/>
    <!--<service prefix="barcode.axd" name="BarcodeImageService"
            type="Devesprit.ImageServer.Services.BarcodeImageService, Devesprit.ImageProcessor.Barcode">
        <setting key="Default.ShowCode" value="true" />
        <setting key="Default.FontFamily" value="Tahoma" />
        <setting key="Default.FontStyle" value="Regular" />
        <setting key="Default.FontSize" value="10" />
        <setting key="Default.BackgroundColor" value="fff" />
        <setting key="Default.ForegroundColor" value="000" />
        <setting key="Default.Opacity" value="100" />
        <setting key="Default.BarWidth" value="0" />
        <setting key="Default.BarHeight" value="0" />
        <setting key="Default.CaptionBelow" value="" />
        <setting key="Default.CaptionAbove" value="" />
        <setting key="Default.RotationAngle" value="0" />
        <setting key="Default.Position" value="0,0" />
        <setting key="Default.Margins" value="1,1,1,1" />
    <!-- Add other service implemtations here. -->