Server

Seal Report includes a Web Report Server to publish and edit your reports on the Web.

On Windows OS, the server must have Internet Information Server (IIS) installed with the option Application Development/ASP.Net 4.5 or greater.

On Linux OS, the server must have ASP .NET Core installed (Refer to https://docs.microsoft.com/en-us/dotnet/core/install/).

Note that the Web Report Server may also act as a Report Scheduler if necessary.
Check Report Schedules for more information.

Web Report Server Publication Wizard (IIS)

To publish the Web Report Server, run the Server Manager and select the menu Configuration->Publish Web Site on IIS... to execute the Web Server Publisher wizard.
If the site was previously published, use the button Publish only files to update the current site.

Web Report Server Publication on Linux or Azure

Check dedicated deployment tutorials.

Server Configuration

Use the Configuration->Configure Server... menu of the Server Manager to configure global parameters for the product.
The server configuration has various properties (e.g. you can configure your default culture, formats and CSV separator using the Format properties.).

Server Scripts

Configure the Audit Script to log the following events in a database: Login, Logout, Report Execution.
Dedicated audit Data Sources and reports are provided and may be adapted to query your audit database.

Use the Report Creation Script to change the default report object when it is created (e.g. adding a specific view or changing a default view parameter), or Report Execution Init Script to modify the report before the execution (e.g. changing a default format).
Common Scripts collection can be used to share functions amongst all scripts used in the product.
Be sure that the Server is local (No internet) property equals true if your server has no access to the internet.
In this case all the Java Scripts and CSS files used in the report result will be loaded from the server.

ASP Session Storage (Pull Request 46)

Session management options
Seal Report Web Server has two options to manage the ASP session:
  • In memory - stored individually in memory not shared between nodes (default)
  • In SQL Server - stored in database, in one table, shared between the nodes.
To store the session in SQL Server, change the configuration in appsettings.json file:
                                    "SealConfiguration": {
                                        "SessionProvider": {
                                            "SqlServer": {
                                                "ConnectionString": "",
                                                "SchemaName": "dbo",
                                                "TableName": "CacheSessions"
                                            }
                                        }
                                    }
                                
SQL Server session storage
To use SQL Server option, besides the configuration, the session table has to be created in the database using the following the .net core tool:
                                    dotnet  tool  install --global  dotnet-sql-cache
                                
When the tool is installed, run the command according to the CLI:
                                    Usage: dotnet sql-cache create [arguments] [options]
                                    Arguments:                                    
                                    [connectionString] The connection string to connect to the database.
                                    [schemaName] Name of the table schema.
                                    [tableName] Name of the table to be created.
                                

PDF and Excel Converter Configurations

If you are using the PDF and Excel converter component, the server configuration contains the Default PDF Configuration and the Default Excel Configuration that are used by default when a conversion is done.

Server Tools

The Server Manager has also Tools menu to check the server Data Sources and Reports.

  • Check Data Sources checks the current Data Source amongst the database (tables, joins and enumerated lists).
  • Refresh Enumerated Lists updates all the values of dynamic enumerated lists. The Data Source must then be saved.
  • Synchronize Report Schedules checks all the schedule of the reports in the repository and synchronize them in the Windows Task Scheduler. The schedule is defined with SYSTEM user.
  • Synchronize Report Schedules with the logged user performs the same but the schedule is defined with the user running the Server Manager.

System Reports

Several useful reports are available in the Reports/System Repository sub-folder to show the current security implementation, to inventory the reports, to check the reports executions, to query the audit database, etc.
System: 100 Configuration - Security Summary System: 200 Audit - Search System: 300 Reports - Inventory

Web Security

The Web Security defines the login process to the Web Report Server through Security Provider and all the user rights through the Security Groups.

Security Provider

The Security Provider defines how the authentication is done when a user wants to login.
All the default Security Providers are defined in *.cshtml files in the /Security/Providers Repository sub-folder.
A Security Script is executed to define the name and the groups of the user. If the user has no group, the authentication has failed.
Depending on his type, a security provider may have parameters (e.g. to configure the LDAP Server name for the LDAP Authentication Provider).

The following Security Providers are available and can be easily modified.
Check the Security Script to have more information.
  • Basic Authentication shows a simple user/password authentication from the user name and password of the login window.
  • Basic Windows Authentication use Windows authentication to validate the user name and password, and define the groups: Windows group names must match group names defined in the security.
  • Database Authentication shows a sample of querying the database to authenticate and get the groups.
  • Integrated Windows Authentication is the same as Basic Windows Authentication but relies on the integrated authentication provided by IIS.
  • LDAP Authentication shows a sample of using the LdapConnection object to authenticate and get the groups.
  • JWT shows how to authenticate a user having a JSON Web Token (JWT) generated by another server sharing a secret key.
  • No Security just adds a security group to the user.
Script sample for the Basic Authentication Provider, the security group is added to the logged user at line 15:
@using Seal.Model
@using Seal.Helpers
@{
    SecurityUser user = Model;
	//Basic authentication script: use the user name and password to authenticate the user and set his name and security groups...
	//user.WebUserName -> user name from the login screen
	//user.WebPassword -> password from the login screen

	user.Name = user.WebUserName; //Display name
	//user.PersonalFolderName -> may be set to defined the personal folder name
	
    //security check can be hardcoded
	if (user.WebUserName == "userName" && user.WebPassword == "password")
	{
		user.AddDefaultSecurityGroup();
		//user.AddSecurityGroup("aGroupName");
	}
	else {
		throw new Exception("Invalid user name or password");
	}
}
                            

Test your security provider

Once your Security Provider configured, user the helper Test a login to fully test a login process with given name and password.

Security Group

After a successful authentication process, the user belongs to one or several Security Groups.

A Security Group allows to configure:
- which repository folders are published for the user,
- if the user can view reports,
- if the user has personal folders,
- which columns, data sources, connections or devices can be selected with the Web Report Designer,
A Security Group has a collection of repository Folders, each folder has a given relative path and right (from No Right to Edit Reports).

If a user belongs to several groups, the following rules are applied:

For the Reports folders
  • Folders: The highest right is used (No right, Execute reports / View files, Execute reports and outputs / View files, Edit schedules / View files, Edit reports / Manage files).
  • Personal folder: The highest right is used (No personal folder, Personal folder for files only, Personal folder for reports and files).
  • Show all folders: True if one group has this flag set to true.
  • Folders, Folder Detail and Menu Scripts are executed sequentially sorted by group name.
For Web Report Designer security
  • SQL Models: Is true if one group has the right to create SQL Models.
  • Devices, Sources, Connections, Columns: Cannot be selected if it is specified in one group.
For Default values
  • The options (Edit Profile, Culture, Logo, Startup) are taken from the group having the highest weight.

A Meta Column may have a Security Tag property. This text can be used to define rights for the designers.

List the current right definitions

The System Report '100 Configuration - Security Summary' generates also a full security summary.
To display rights per user, it may be adapted to match the security provider used.
System: 100 Configuration - Security Summary
Security Objects
Check also Seal Report Library (Seal.Model namespace) for more information.

Custom Publications

In addition to the security applied on report folders, dedicated scripts (properties of a Security Group) allow to modify the reports published to the logged user.

  • Folder Script: Optional script executed to define/modify the folders published in the Web Report Server.
  • Folder Detail Script: Optional script executed to define/modify the reports published in the Web Report Server for a given folder.
  • Menu Script: Optional script executed to define/modify the reports of the logged user.

If the user belongs to several groups, scripts are executed sequentially sorted by group name.

Folder Detail Script sample to filter 'Charts' reports in the /Samples folder:
@{
    SecurityUser user = Model;
     if (user.FolderDetail.folder.path == @"\Samples") {
        //Sample to filter reports
        user.FolderDetail.files = user.FolderDetail.files.Where(i => i.name.Contains("Charts")).ToList(); 
    }
}
                            

Seal Web Interface

Once installed, the Web Report Server offers a simple interface to ease the integration of Seal Report into existing web sites.

Check the API Description and Samples at https://sealreport.org/demo/WebInterfaceAPI.html.

Contribute to Seal Report

Enhance the documentation and samples

Want to share your experience or to add a new topic ? Something is not clear in the documentation ? Do you have an interesting recipe ?
As the site for the documentation is part of the solution, you are welcome to Pull a Request at GitHub.

Add translation files

Do you have a translation file not yet supported by Seal Report ?
Check first the recipe Adding translation files.
As the translations are part of the project, feel free to Pull a Request at GitHub.

And more...

You are also welcome to help us in several different areas:
  • Beta testing.
  • Libraries of Data Sources and Reports on standard databases.
  • Additional View templates.
  • New features development.
Please feel free to contact us at Ariacom or use GitHub if you are interested in contributing to Seal Report.