This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
component { | |
public function addCertToStore(required string certBase64, required string keyStorePath, string keyStorePassword="insecure") { | |
if (not fileExists(keyStorePath)) { | |
throw(message='Path of [keyStorePath] does not exist!', detail="#keyStorePath#"); | |
} | |
local.ks = getKeyStore(keyStorePath, keyStorePassword); | |
local.tempPath = getTempDirectory() & createUUID() & ".tmp"; | |
fileWrite(local.tempPath, "-----BEGIN CERTIFICATE-----#chr(10)##certBase64##chr(10)#-----END CERTIFICATE-----"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfoutput> | |
#getMem()# | |
</cfoutput> | |
<cfscript> | |
function getMem(){ | |
var runtime = createObject('java', 'java.lang.Runtime').getRuntime(); | |
var maxMemory = runtime.maxMemory(); | |
var allocatedMemory = runtime.totalMemory(); | |
var freeMemory = runtime.freeMemory(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8" ?> | |
<configuration> | |
<system.web> | |
<customErrors mode="Off" /> | |
</system.web> | |
<system.webServer> | |
<httpErrors errorMode="Detailed" /> | |
<rewrite> | |
<rules> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset maxErrors = 500 /> | |
<cfset root = expandPath('/') /> | |
<cfset files = directoryList(root, true, "path", "*.cfm|*.cfc|*.html|*.htm") /> | |
<cfset currErrors = 0 /> | |
<cfoutput> | |
<p>#arraylen(files)# cfm/cfc/html/htm files found</p> | |
</cfoutput> | |
<table border="1"> | |
<thead> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfset jarsPath = expandPath('/java/barcode4j/') /> | |
<!--- Path where the necessary jar files are located (downloadable from https://www.dropbox.com/s/skl9fwky2n7mnjr/java-files-barcode4j.zip?dl=0) ---> | |
<cfset libraryList = arrayToList( directoryList(jarsPath, false, 'array', '*.jar') ) /> | |
<cfset configBuilder = createObject('java', 'org.apache.avalon.framework.configuration.DefaultConfigurationBuilder', libraryList) /> | |
<cfset barcodeUtil = createObject('java', 'org.krysalis.barcode4j.BarcodeUtil', libraryList) /> | |
<cfset grayImageType = createObject('java', 'java.awt.image.BufferedImage').TYPE_BYTE_GRAY /> | |
<!--- create custom config. See http://barcode4j.sourceforge.net/2.1/symbol-ean-13.html ---> | |
<cfset configXml = '<barcode> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- SQLDate:[2013-06-28 13:48:50 ########################## prodid not received ########################## --> | |
<!-- Exception in doEndTag() in tag com.openmarket.gator.jsp.assetset.Getattributevalues in page 'Staatsloterij/Content_C/renderBonProduct' in element 'Content_C/renderBonProduct' errno: 0 errdetail1: Exception in doEndTag() in tag com.openmarket.gator.jsp.assetset.Setasset in page 'Staatsloterij/Content_C/renderBonProduct' in element 'Content_C/renderBonProduct' errno: -500 errdetail: 0 com.openmarket.basic.interfaces.AssetException: Invalid type specified: Content_C errdetail: 0 java.lang.Exception: object lookup for myBon_Content failed! --></div><!-- End content --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cfhttp url="http://blog.bittersweetryan.com/2011/02/post-some-cf-code-on-github-and-win.html" /> | |
<cfset possibleWinners = {} /> | |
<cfset commentsHtmlArr = rematch("<dt class='comment-author.*?</dd>", rereplace(cfhttp.filecontent, '[\r\n]+', '', 'all')) /> | |
<cfset gistURLRegex = "https://gist\.github\.com/[0-9]+" /> | |
<cfloop from="1" to="#arrayLen(commentsHtmlArr)#" index="arrIndex"> | |
<cfset currHtml = commentsHtmlArr[arrIndex] /> | |
<cfif refindNoCase(gistURLRegex, currHtml)> | |
<cfset gistURL = reMatchNoCase(gistURLRegex, currHtml) /> | |
<cfset gistURL = gistURL[1] /> |