Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Argument Exception: Option not supported. (Parameter 'ssl ca') #705

Open
sifaqes opened this issue Jul 9, 2024 · 1 comment
Open

Argument Exception: Option not supported. (Parameter 'ssl ca') #705

sifaqes opened this issue Jul 9, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@sifaqes
Copy link

sifaqes commented Jul 9, 2024

Describe the bug
An unhandled exception occurred while processing the request. The application throws an ArgumentException with the message "Option not supported. (Parameter 'ssl ca')" when trying to set the connection string for MySQL with SSL in a FastReport.

To Reproduce
Steps to reproduce the behavior:

Go to the report generation endpoint.
Provide the required parameters to trigger the report generation.
The system attempts to load the MySQL connection string with SSL.
See error

Expected behavior
A clear and concise description of what you expected to happen.
The report should generate successfully using the MySQL connection with SSL enabled.

ArgumentException: Option not supported. (Parameter 'ssl ca')
System.Data.Common.DbConnectionStringBuilder.set_ConnectionString(string value)
MySql.Data.MySqlClient.MySqlConnectionStringBuilder..ctor(string connectionString, bool isAnalyzed)
MySql.Data.MySqlClient.MySqlConnection.set_ConnectionString(string value)
FastReport.Data.DataConnectionBase.GetConnection()
FastReport.Data.DataConnectionBase.FillTableData(DataTable table, string selectCommand, CommandParameterCollection parameters)
FastReport.Data.DataConnectionBase.FillTable(TableDataSource source)
FastReport.Data.TableDataSource.LoadData(ArrayList rows)
FastReport.Data.DataSourceBase.LoadData()
FastReport.Data.DataSourceBase.Init(Relation relation, string filter, SortCollection sort, bool useAllParentRows)
FastReport.Data.DataSourceBase.Init(DataSourceBase parentData, string filter, SortCollection sort, bool useAllParentRows)
FastReport.DataBand.InitDataSource()
FastReport.Engine.ReportEngine.RunDataBand(DataBand dataBand)
FastReport.Engine.ReportEngine.RunBands(BandCollection bands)
FastReport.Engine.ReportEngine.RunReportPage(ReportPage page)
FastReport.Engine.ReportEngine.RunReportPages()
FastReport.Engine.ReportEngine.RunReportPages(ReportPage page)
FastReport.Engine.ReportEngine.RunPhase2(bool append, ReportPage page)
FastReport.Engine.ReportEngine.Run(bool runDialogs, bool append, bool resetDataState, ReportPage page)
FastReport.Engine.ReportEngine.Run(bool runDialogs, bool append, bool resetDataState)
FastReport.Report.Prepare(bool append)
FastReport.Report.Prepare()
matelaslux.Controllers.ReportController.GenerateReport()
lambda_method395(Closure , object , object[] )
Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor+SyncActionResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, object controller, object[] arguments)
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeActionMethodAsync()
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(ref State next, ref Scope scope, ref object state, ref bool isCompleted)
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeNextActionFilterAsync()
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(ref State next, ref Scope scope, ref object state, ref bool isCompleted)
Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeInnerFilterAsync()
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, object state, bool isCompleted)
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(ref State next, ref Scope scope, ref object state, ref bool isCompleted)
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeFilterPipelineAsync()
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context)
Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)

Screenshots

Captura de pantalla 2024-07-09 033956

Device (please complete the following information):

  • OS: Windows 11 Pro
  • Browser Chrome
  • Version FastReport.Community.2024.2.0.zip
    Version: MariaDB: 11.3.1-MariaDB

Additional context
The error occurs when setting up a MySQL connection string with SSL in a FastReport. The connection string includes the parameter 'ssl ca' which is causing the issue. The certificate file is located at "c:\MyApp\Config\Aiven\ca.pem".

@sifaqes sifaqes added the bug Something isn't working label Jul 9, 2024
@sifaqes
Copy link
Author

sifaqes commented Jul 9, 2024

The issue has been resolved, the database provider offers a .pem certificate. I added it to the FastReport Community program and that caused the error; MySQL does not recognize or support Ssl Ca.

The solution is to remove the .pem file from the program.

I believe that FastReport OpenSource has saved many developers from high costs for medium and small applications. I like it a lot.

I hope that one day the free version will be supported.

--- (_)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant