There seems to be a potential bug in ColdFusion 2021 Query of Queries. Today I ran into this error: Index 5 out of bounds for length 5 null The index bounds will change based on the number of columns in the query as explained below. This error was being thrown in a very basic QoQ: […]
read moreI found that after changing the password for a MongoDB NoSQL DSN using ColdFusion Administrator you need to restart the ColdFusion Application service in Windows. Even changing to the correct password will cause a MongoDB authentication error: Exception authenticating MongoCredential{mechanism=SCRAM-SHA-256, userName='{Your Username}’, source='{Your Auth Source}’, password=, mechanismProperties=} null Command failed with error 18 (AuthenticationFailed): ‘Authentication […]
read moreIf the checkboxes within the WordPress Admin do not appear checked. You may need to verify that your Content-Security Policy (CSP) allows “data:” as a source. Example: default-src data: ‘self’ *.googleapis.com *.gstatic.com;
read moreIn ColdFusion 2021 I encountered a new wrinkle when using CFHTTP. The url attribute must contain no leading or trailing spaces: <cfhttp url=”#trim(someurlvariable)#”> In my case the value of someurlvariable was coming from a database.
read moreAnother potential bug found within ColdFusion 2021 with this error: Could not initialize class cfApplication2ecfmXXXXXXXXX Interestingly the TYPE of error was: java.lang.NoClassDefFoundError The class name cfApplication2ecfmXXXXXXXXX indicated to me that it was an issue with the saved class files in {CFRoot}\cfusion\wwwroot\WEB-INF\cfclasses The file cfApplication2ecfmXXXXXXXXX.class did exist in the \cfclasses folder The only working solution I’ve […]
read moreDateFormat() in ColdFusion 2021 is now case-sensitive. This no longer produces the desired result: <cfoutput>#dateFormat(“11/21/2020 2:38:16 PM”,”MM/DD/YYYY”)#</cfoutput> Pre-ColdFusion 2021: 11/21/2020 ColdFusion 2021: 11/326/2020 Note that ColdFusion 2021 displays the day of the year To fix: <cfoutput>#dateFormat(“11/21/2020 2:38:16 PM”,”mm/dd/yyyy”)#</cfoutput> UPDATE Adobe has added a JVM flag that can adjust this behavior: -Dcoldfusion.datemask.useDasdayofmonth which defaults to FALSEhttps://helpx.adobe.com/coldfusion/cfml-reference/coldfusion-functions/functions-c-d/DateFormat.html […]
read moreBelow are some common PCI DSS flagged HTTP response headers and how to easily fix them using IIS and the URL Rewrite module. Server Response Header This header discloses information about your web server software and version. Example: Microsoft-IIS/10.0 Action: REMOVE URL Rewrite Rule: <configuration> <system.webServer> <rewrite> <outboundRules rewriteBeforeCache="true"> <rule name="Remove Server header"> <match serverVariable="RESPONSE_Server" […]
read moreIn Windows (not sure of *nix OS) the GPG command-line has an obscure switch necessary in order to use the ‐‐passphrase argument: ‐‐pinentry-mode (https://gnupg.org/documentation/manuals/gpgme/Pinentry-Mode.html) Example: gpg ‐‐pinentry‐mode loopback ‐‐batch ‐‐yes ‐‐passphrase "<PassPhrase>" "<File>"
read moreReferencing a PSObject property with special characters is pretty easy: $var = $psobject.”Property With Space” In order to reference properties that include special characters dynamically: $propertyname = “Property With Space” $var = $psobject.($propertyname)
read moreThis post is really more about the potential problems one might encounter using Send-MailMessage cmdlet in PowerShell to connect and send email via Office 365. First a quick example: [SecureString]$o365Password = ConvertTo-SecureString “Your Office 365 Account Password” -AsPlainText -Force [PSCredential]$o365Credentials = New-Object System.Management.Automation.PSCredential(“Your Office 365 Account Username”,$o365Password) Send-MailMessage ` -Subject “Your Subject” ` -Body “Your […]
read more