summaryrefslogtreecommitdiffstats
path: root/openssl-model.lua
diff options
context:
space:
mode:
Diffstat (limited to 'openssl-model.lua')
-rw-r--r--openssl-model.lua6
1 files changed, 2 insertions, 4 deletions
diff --git a/openssl-model.lua b/openssl-model.lua
index bcaf477..fb28cb6 100644
--- a/openssl-model.lua
+++ b/openssl-model.lua
@@ -103,17 +103,15 @@ local create_subject_string = function(values, ignorevalues)
end
for name,value in pairs(values.value) do
name = name:gsub(".*%.", "") -- remove the "0." from the front
- value.value = value.value:gsub("[/=]", "\%1") -- escape characters
if (short_names[name] or reverseshorts[name]) and value.value and value.value ~= "" then
name = short_names[name] or name
- outstr[#outstr + 1] = name .. "=" .. value.value
+ outstr[#outstr + 1] = name .. "=" .. value.value:gsub("[/=]", "\\%1") -- escape characters
end
end
for name,value in pairs(values.value) do
name = name:gsub(".*%.", "") -- remove the "0." from the front
- value.value = value.value:gsub("[/=]", "\%1") -- escape characters
if not reverseignore[name] and not short_names[name] and not reverseshorts[name] and value.value and value.value ~= "" then
- outstr[#outstr + 1] = name .. "=" .. value.value
+ outstr[#outstr + 1] = name .. "=" .. value.value:gsub("[/=]", "\\%1") -- escape characters
end
end
return "/"..table.concat(outstr, "/")