{"record":{"id":"d041ceebefed77d2","repo":"theforeman/foreman","slug":"ssl-ca-file-not-found-check-the-server-ca-file","errorCode":null,"errorMessage":"SSL CA file not found, check the 'Server CA file' and 'SSL CA file' in Settings > Authentication","messagePattern":"SSL CA file not found, check the 'Server CA file' and 'SSL CA file' in Settings > Authentication","errorType":"exception","errorClass":"Foreman::Exception","httpStatus":null,"severity":"error","filePath":"app/services/foreman/renderer/scope/macros/base.rb","lineNumber":393,"sourceCode":"          def foreman_server_ca_cert(server_ca_file_enabled: true, ssl_ca_file_enabled: true)\n            setting_values = []\n            setting_values << Setting[:server_ca_file] if server_ca_file_enabled\n            setting_values << Setting[:ssl_ca_file] if ssl_ca_file_enabled\n\n            raise UndefinedSetting.new(setting: '\"Server CA file\" or \"SSL CA file\"') if setting_values.reject(&:empty?).empty?\n\n            files_content = setting_values.uniq.compact.map do |setting_value|\n              File.read(setting_value)\n            rescue StandardError => e\n              Foreman::Logging.logger('templates').warn(\"Failed to read CA file: #{e}\")\n\n              nil\n            end\n\n            result = files_content.compact.join(\"\\n\")\n\n            msg = N_(\"SSL CA file not found, check the 'Server CA file' and 'SSL CA file' in Settings > Authentication\")\n            raise Foreman::Exception.new(msg) unless result.present?\n\n            result\n          end\n\n          apipie_method :rand, 'Returns random floating point numbers between 0 and 1' do\n            desc 'When the attribute is smaller or equal to 1, the function return float. Otherwise it returns integer. '\n            optional :args, ::Float, desc: 'Can take a parameter as max value for random number. For negative and float numbers produce interesting outputs'\n            returns ::Float\n            example 'rand #=> 0.5\n                     rand #=> 0.8\n                     rand(100) #=> 23\n                     rand(100) #=> 72'\n          end\n\n          apipie :method, \"Return the concatenated array with correct line break\" do\n            desc 'This method returns concatenated array with correct line break with the respect of output format.\n                  For HTML output, it joins array members with <br> tag otherwise it uses a \\n character.\n                  It works as new line at CSV but at YAML and JSON it is used for separating of lines","sourceCodeStart":375,"sourceCodeEnd":411,"githubUrl":"https://github.com/theforeman/foreman/blob/6b05625475cfe6aac31a88f8c8ee6e62e4efe620/app/services/foreman/renderer/scope/macros/base.rb#L375-L411","documentation":"Error \"SSL CA file not found, check the 'Server CA file' and 'SSL CA file' in Settings > Authentication\" thrown in theforeman/foreman.","triggerScenarios":"Thrown at app/services/foreman/renderer/scope/macros/base.rb:393 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6b05625475cfe6aac31a88f8c8ee6e62e4efe620","analyzedAt":"2026-08-23T17:46:34.094Z","schemaVersion":2},"datasetVersion":"2026-08-23T21:17:23.414Z"}