Quantcast
Channel: Adobe Community : Unanswered Discussions - ColdFusion
Viewing all 5794 articles
Browse latest View live

Coldfusion with Apache, RESTful API on port 80

$
0
0

Hi,

we have installed Coldfusion 2018 with Apache web server and CF Api Manager on our SUSE server.

We have many CF instances and one of these provides some RESTful services.

 

I configured apis in the CF Api Manager and now our REST enpoints are accessible at ports 9100 and 9151 (ajp), but we want our customers to use this services with port 80 keeping other ports closed.

 

The endpoints are located somewhere like https://our_domain1.com/rest/services/ ..

 

 

So i've modify the following two Apache configuration files:

 

1) worker.properties

 

i added a new worker in the worker list (example name: "newworker") and i defined it in this way:

 

worker.our-cf-instance.type=ajp13

worker.our-cf-instance.host=localhost

worker.our-cf-instance.port=9151

worker.our-cf-instance.connection_pool_timeout=60

worker.our-cf-instance.max_reuse_connections=250

worker.our-cf-instance.connection_pool_size=500

worker.our-cf-instance.lbfactor=1

worker.our-cf-instance.route=newworker

 

 

2) uriworkermap_our-cf-instance.properties (in /opt/coldfusion2018/config/wsconfig/1/)

 

i set the new worker for /rest/*

 

/rest/* = newworker

 

----

 

It works, now the endpoints are reachable through port 80, and apache matches requests containing "/rest/*" and routes them to port 9151 (ajp of API Manager Proxy)

 

i would like to know: it's this the best way?

 

could it introduce some security issues?

 

is there a better way to achieve that?

 

 

Thank you


Installing Coldfusion 2016 32-bit on Windows 2016

$
0
0

I am having issues trying to install Coldfusion 2016 32-bit on Windows 2016.  I can get the executable to run but it completes with errors.  It looks like it only partially installs.  There is nothing in the install error log that is helpful (or I don't understand it). 

 

We are loading 32-bit because we require 'MS Access with Unicode' for a datasource.  We are migrating Coldfusion 2016 32-bit from Windows 2008 version where it installed fine. Is there something about Windows 2016 where this won't install?  If someone has done this successfully, that would be helpful information.

API Manager: Pass bearer token to endpoint

$
0
0

I am currently implementing an API using the OAuth2: Client credentials authentication.  The oauth is working to a degree but when after API manager proxies the request to the Coldfusion endpoint, it is removing the authorization header.  Is there any way to preserve the header?  My main reasoning is that I need a way to identify the user on the CF server side after going through API manager.  Thanks in advance.

Connect ColdFusion 2016 Enterprise with Oracle 12 and above

$
0
0

Hi,

 

a customer is going to update their Oracle and announced they are setting SQLNET.ALLOWED_LOGON_VERSION_SERVER to 12. This means the client driver has to be version 11.2 or later.

In previous discussions I always sad simply use a recent Thin driver and everything's fine.

I found this query that says which client you are on

    SELECT DISTINCT s.client_version     FROM v$session_connect_info s     WHERE s.sid = SYS_CONTEXT('USERENV', 'SID')

I run it from a cfquery tag in a ColdFusion script and everything is fine when I use a recent Thin driver, they report back version 12 or 18 or something.

I also ran it in ColdFusion 2016 with Updater 10 installed. I connected to Oracle using the built in driver (Developer Edition/Enterprise). I got 11.1.0.7.0 as my client version. This is lower than the driver recommended to connect to Oracle 12 with (11.2).

Does anyone have a recent Oracle running and set ALLOWED_LOGON_VERSION_SERVER to a high value (at least 12)? Does this work with the driver ColdFusion 2016 comes with?

 

Here's a matrix that shows which client can connect to which server version: Oracle DBA Blog Apps DBA Blog: java.sql.SQLException: ORA-28040: No matching authentication protocol

 

Best,

Bernhard

Adding external rest service to CF Admin and consuming

$
0
0

Hi,


I use the following code to consume a rest service in my local ColdFusion application (and it works fine) but I am trying to add it into the ColdFusion administrator so I can manage the rest service from the admin rather than having a URL in local code.  I then just want to simply call it from my local code.

 

Is this possible?  How do I achieve this?

 

-----------------------------------------

<cfhttp

url="[URL goes here]?LH_ADDRESS=#parameter#"

method="get"

result="res"/>

-----------------------------------------

 

Many Thanks,
George

Feature request - IP debug description field

$
0
0

I have asked several Adobe support people over the years for this tiny feature but it's not in 2018 even though I was told it would be

 

In debugging section ... where it asks what IP addresses should include debugging data on screen, and we put the IP addresses in, it would be helpful to have a description field next to it so we know whose IP address it is?

 

Same in IIS ... no description!

 

Unless ... ... is there a way to add a delimiter and add a description?  Like: 

122.122.122.122; Stans workstation

solrconfig.xml missing luceneMatchVersion

$
0
0

Hi all,

 

I'm using the addons docker image as part of setting my app up for local development using Docker as well as preparing to deploy to AWS ECS.

 

I've managed to connect to Solr from the CF Admin and I can access the Solr admin on my local machine as well.

 

However, when I try to create a new collection, I'm getting this error:

 

solrconfig.xml missing luceneMatchVersion

 

In my docker-compose.yml file I have"

 

  addons:    container_name: mycfaddons    image: eaps-docker-coldfusion.bintray.io/cf/addons    environment:      - acceptEULA=YES      - configureExternalAddons=true      - addonsHost=addons      - addonsPort=8991      - addonsUsername=admin      - addonsPassword=admin    ports:      - "8991:8991"    networks:      - webnet

 

 

If I go into the CF Admin, I have the solr hostname as "addons" and the solr home directory as: "/opt/coldfusionaddonservices/solr"

 

I can see this error happen in the logs of the solr admin as soon as I attempt to create the collection, so I know the two are communicating with one another. I'm just not sure why this error is popping up.

 

Has anyone encountered this and have a solution?

 

Thank you,

Ben

CFPDF

$
0
0

Bonjour,

 

Je voudrais prendre un pdf d'un livre pour l'insérer dans un fichier mais je voudrais aussi la mise en page basique.

Voici mon code :

 

<cfpdf action = "extracttext" source = "chemin" name = "myXML"/> <cfcontent type = "text/html" />

<cfoutput> #myXML# </cfoutput>

 

J'arrive à récupérer le texte mais sans la mise en page !

 

Merci par avance pour votre aide.


How to disable http TRACE method in jetty 9.4?

$
0
0

Coldfusion 11. I use server monitoring, which is configured on jetty.port.How to disable http TRACE, OPTIONS methods on jetty.port?

ColdFusion 2018 cfchart type="html" works in Chrome but not in IE

$
0
0

Chart example testchart.cfm

 

<cfscript>

     background={}; 

       background={"color":"red","color-2":"white"};

       legend={"background-color":"pink","vertical-align":"bottom","layout":"horizontal","align" :"center"};

       yAxis={"label":{"text":"Some value","color":"red","font-size":"20px"}};

       xAxis={"item":{"font-angle":45}};

    plot={"value-box":{

            "type":"all",

            "text":"%v",

            "text-align":"center",

            "alpha":0.5,

    "placement":"top-in",

    "font-color":"black",

"font-weight":"bold",

"font-family":"arial",

"font-size":"15px",

    "background-color":"none",

            "background-color-2":"none",

            "border-color":"none",

            "border-width":1}};

</cfscript>

 

<cfchart

   format="html"

   scalefrom="0"

   scaleto="2000000"

   showLegend="yes"

  legend="#legend#" 

   seriesPlacement="stacked"   

   showMarkers="yes"

yAxis="#yAxis#"

xAxis="#xAxis#"

   chartheight="400"

plot="#plot#"

   chartwidth="600"

   background="#background#" >

  <cfchartseries

      type="bar"

      serieslabel="Website Traffic 2016"

      seriescolor="lime">

    <cfchartdata item="January" value="503100" >

    <cfchartdata item="February" value="720310">

    <cfchartdata item="March" value="688700">

    <cfchartdata item="April" value="986500">

    <cfchartdata item="May" value="1063911">

    <cfchartdata item="June" value="1115321">

   </cfchartseries>

  

  <cfchartseries

      type="bar"

      serieslabel="Website Traffic 2015"

      seriescolor="yellow">

    <cfchartdata item="January" value="#RandRange(300000, 900000)#">

    <cfchartdata item="February" value="#RandRange(300000, 900000)#">

    <cfchartdata item="March" value="#RandRange(300000, 900000)#">

    <cfchartdata item="April" value="#RandRange(300000, 900000)#">

    <cfchartdata item="May" value="#RandRange(300000, 900000)#">

    <cfchartdata item="June" value="#RandRange(300000, 900000)#">

  </cfchartseries>

</cfchart>

</html>

 

Works in Chrome

 

 

 

but not in IE.  In IE  (all versions)

 

 

 

Does anyone know why this may be happening? 

Coldfusion: Dreaweaver CC vs Dreamweaver CSS.5- can I make it like it used to be?

$
0
0

I've recently changed from Dreamweaver CSS.5 to Dreamweaver CC.  There are a number of little differences that make a BIG difference in usability.

I finally found (through an internet search) where "Search local site" is.

 

When I attempt to close a tag with </, the autofill is almost never the tag I opened.

 

When using block comments with <!---   --->
If there is a comment IN that block comment, the color change terminates.

 

Auto indent is really just messed up...I had to turn it off.

 

So the basic question is....

 

Is there a way to make Dreamweaver CC work more like Dreamweaver CSS.5?

 

It is not my opinion that these are all "things you are used to" kind of problems.  These are changes that were made that a) don't work the way they were supposed to and b) are NOT a step forward.

Replacing cfwindow?

$
0
0

I've been using CFwindow for years and find it very old fashioned.

 

Have to use this code to open a window ...

 

<cfwindow width="#srw#" height="700" bodystyle="overflow:auto"

name="Alerts" title="Alerts" modal="True"

closable="true" draggable="true" resizable="true"  initshow="false"

/>

 

then trigger it with

 

ColdFusion.navigate('/members/edit/edit.cfm','MemberProfileEdit');

rePositionWindow('MemberProfileEdit');

ColdFusion.Window.show('MemberProfileEdit');

 

ColdFusion.Window.hide('pRC')

 

I am also told by another developer that this usage is archaic and inefficient, in that the cfwindow line actually opens the window on initial load.

 

Also having problems getting a cfwindow to "find" javascript that is declared outside of it.

 

What in jquery can one use that is today's standards?

coldfusion and bigquery

$
0
0

Anyone have any experience setting up the Simba JDBC driver for Google BigQuery using service account authentication?

The problem seems to be reading the file  which is defined in the OAuthPvtKeyPath which is a part of the JDBC URL.

When I submit the form with the JDBC URL, Driver Class, Driver Name etc I receive the following error:

java.sql.SQLNonTransientConnectionException: [Simba][JDBC](10100) Connection Refused: [Simba][JDBC](11640) Required Connection Key(s): OAuthPvtKeyPath, OAuthServiceAcctEmail, ProjectId

 

All three parameters (OAuthPvtKeyPath, OAuthServiceAcctEmail and Projectid) is part of the JDBC URL like this example from the Simba JDBC driver user manual (except from the OAuthPvtKeyPath which is the path I'm using on my Mac):

 

jdbc:bigquery://https://www.googleapis.com/bigquery/v2:443;

ProjectId=MyBigQueryProject;OAuthType=0;

OAuthServiceAcctEmail=bqtest1@data-drivertesting.

iam.gserviceaccount.com;

OAuthPvtKeyPath=/Applications/ColdFusion2018/cfusion/lib/myfilewithkeys.json;

CF11: Problem with ImageResize()

$
0
0

Hello, all,

 

I've got an issue that has me perplexed.

 

We have a section on our restricted site for news.  There is an admin panel that allows someone (authorized) to create/edit news articles, and one of the optional fields is for uploading an image.

 

Now, so far this hasn't really presented any problems.  Until today, every image that was uploaded fit a particular format ratio, so everything appears correct.

 

Today, two images that are much more wide compared to the height have been uploaded.  When viewing the actual article, it looks okay.  However, on the 'landing' page of the site, there is a carousel that rotates among four selected articles that contain an image, along with four clickable thumbnails on the right side.  For both the thumbnails and the full-size image associated with it, those two images extend past the right of the image space, I'm assuming it's using overflow: hidden;.

 

I tried to update the page that processes the form, using imageInfo() to check height/width of all images, and use resizeImage() to bring the dimensions down.  First I check the height, and if it's more than 325px I resize it down to 325px.  Then I check for width, and if the width is greater than 528px, I resize it down to 528px.

 

But the images are pixelated and blurry.  I've put the old page back, for now, but would really like to understand why the jpg images are pixelated and blurry after going through resizeImage().

 

<cfif info.height gt 325>     <cfset imageResize(myImage,"","325","highestQuality",0) /></cfif><cfif info.width gt 528>     <cfset imageResize(myImage,"528","","highestQuality",0) /></cfif>

 

V/r,

 

^ _ ^

Finding JSON errors in .cfc

$
0
0

I am rendering a screen using AJAX / and a cfc. (No reloads)

All goes well until I make a boo boo and get a JSON error.

I know what causes it - text that should not be in the cfc. 

But now I've hit a brick wall.  I cannot find the "extra text" that's causing it.

 

Or ... is that the only cause?

 

The odd thing is the application runs fine on the bets server but not on localhost.

 

So I looked for any / all instances of "localhost" or 127.0.0.1 and nothing problematic.

 

Is there a tool out here that scans cfc's for these silly errors?

I have looked in the server admin logs but I have no idea which of the log files would house it.

Usually only use application.log

 

Thanks


Taking photo using webcam ...

$
0
0

Not specific to CF, maybe Javascript or Jquery ... looked everywhere on google and found nothing.

So I am on a web site the other day and in addition to being able to upload your government issued photo id, you could also say cheese and

have your built in laptop web cam take your photo.

 

How do you do that?  What library tool?

cfchart and 508 compliance

$
0
0

I'm looking for a way to add a text equivalent to a rendered cfchart. I've read documentation for CF11 that states "Some complex controls such as cfmap and cfchart do not include text alternatives for some image," and you cannot add an alt tag to <cfchart>. However, the same documentation states "ColdFusion charts do provide any text equivalents for non-text elements."

 

Adobe ColdFusion 11 - Section 508 Voluntary Product Accessibility Template

 

How is this achieved?

Coldfusion 2018 Lockdown Tool failure

$
0
0

Hi folks,

 

I am hoping someone can point me in the right direction to fixing a problem I am having with the lockdown tool. I have been following the CF2018 lockdown guide, I installed Coldfusion 2018 developer edition on a Server 2016 OS.

 

  • I applied hotfix 3, only weird thing I found was that the ODBC server service would not start after.
  • I checked the hotfix log and found no errors.
  • Spent of a ton of time researching that problem, found there was issues in previous versions of CF, realized I don't have any ODBC datasources to worry about, so I set the ODBC Agent and ODBC Server service to be disabled following guidance from several of those threads.
  • Successfully logging into CF Administrator. Followed the guide.
  • Ran the lockdown tool following the guide, only major change's was that I selected no to the coldfusion update since I manually updated it, and I had the lockdown tool create the ColdFusion Runtime User for me. In checking the lockdown the log, I found it successfully created the user at one point, before it reverted several of the changes it made. This tells me the windows administrator account password should have been correct.
  • The lockdown failed, relevant log entries below:

 

I am hoping someone can shed some light on what may cause this failure. Thanks in advance for your help.

 

JD

 

 

2019-05-31 09:26:45 INFO  - Change Permissions of ColdFusion file system: Error Logs

2019-05-31 09:26:45 INFO  -

2019-05-31 09:26:45 INFO  - Permissions changed for the user: IUSR for the path: "D:\ColdFusion2018\cfusion\wwwroot\cf_scripts"

2019-05-31 09:26:45 INFO  - Folder permissions changed!

2019-05-31 09:26:45 INFO  - Successfully setup file system permissions for ColdFusion!

2019-05-31 09:26:45 INFO  - Setting up registry permissions for ColdFusion!

2019-05-31 09:26:45 INFO  - Now starting to change registry permissions!

2019-05-31 09:26:45 INFO  - ColdFusion version is: 2018

2019-05-31 09:26:45 INFO  - Now getting all registry keys!

2019-05-31 09:26:45 INFO  - All registry keys to change received!

2019-05-31 09:26:46 INFO  - Registry permissions were successfully changed!

2019-05-31 09:26:46 INFO  - Successfully changed the registry permissions for ColdFusion!

2019-05-31 09:26:46 INFO  - Changing logon users for ColdFusion services

2019-05-31 09:26:46 INFO  - Trying to change logon user for ColdFusion

2019-05-31 09:26:47 INFO  - Changing for: ColdFusion2018Add-onServices

2019-05-31 09:26:47 INFO  - [SC] ChangeServiceConfig SUCCESS

 

 

2019-05-31 09:26:47 INFO  - Changing for: ColdFusion 2018 Application Server

2019-05-31 09:26:47 INFO  - [SC] ChangeServiceConfig SUCCESS

 

 

2019-05-31 09:26:47 INFO  - Changing for: ColdFusion 2018 ODBC Agent

2019-05-31 09:26:47 INFO  - [SC] ChangeServiceConfig SUCCESS

 

 

2019-05-31 09:26:47 INFO  - Changing for: ColdFusion 2018 ODBC Server

2019-05-31 09:26:47 INFO  - [SC] ChangeServiceConfig SUCCESS

 

 

2019-05-31 09:26:47 INFO  - All permissions changed!

2019-05-31 09:26:47 INFO  - Restarting ColdFusion using ColdFusion services!

2019-05-31 09:26:47 INFO  -

The ColdFusion 2018 Add-on Services service was stopped successfully.

 

 

 

 

2019-05-31 09:26:57 INFO  - The ColdFusion 2018 Application Server service is stopping....

The ColdFusion 2018 Application Server service was stopped successfully.

 

 

 

 

2019-05-31 09:26:57 INFO  - The ColdFusion 2018 ODBC Agent service is not started.

 

 

More help is available by typing NET HELPMSG 3521.

 

 

 

 

2019-05-31 09:26:57 INFO  - The ColdFusion 2018 ODBC Server service is not started.

 

 

More help is available by typing NET HELPMSG 3521.

 

 

 

 

2019-05-31 09:26:57 INFO  - Not all services could be stopped!

2019-05-31 09:27:00 INFO  - The ColdFusion 2018 Add-on Services service could not be started.

 

 

A system error has occurred.

 

 

System error 1067 has occurred.

 

 

The process terminated unexpectedly.

 

 

 

 

2019-05-31 09:27:05 INFO  - The ColdFusion 2018 Application Server service could not be started.

 

 

A service specific error occurred: 2.

 

 

More help is available by typing NET HELPMSG 3547.

 

 

 

 

2019-05-31 09:27:05 INFO  - System error 1058 has occurred.

 

 

The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.

 

 

 

 

2019-05-31 09:27:05 INFO  - System error 1058 has occurred.

 

 

The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.

 

 

 

 

2019-05-31 09:27:05 INFO  - Not all services could be restarted!

2019-05-31 09:27:05 INFO  - All ColdFusion services restarted successfully!

2019-05-31 09:27:05 INFO  - Successfully changed the logon users for ColdFusion services!

2019-05-31 09:27:05 INFO  - Trying to restart ColdFusion

2019-05-31 09:27:05 INFO  - ColdFusion restarted successfully!

2019-05-31 09:27:05 INFO  - Setting up virtual directory for cf_scripts!

2019-05-31 09:27:05 INFO  - Trying to add virtual directory for cf_scripts

2019-05-31 09:27:05 INFO  - Adding virtual directory for cf_scripts!

2019-05-31 09:27:06 INFO  - Successfully added virtual directory for cf_scripts!

2019-05-31 09:27:06 INFO  - Changing scripts source in ColdFusion Administrator

2019-05-31 09:27:07 INFO  - Old Value for scripts source: none

2019-05-31 09:27:07 INFO  - It seems there has been an error while getting the script source values.

2019-05-31 09:27:07 INFO  - Failed to change cf_scripts source in Administrator

2019-05-31 09:27:07 INFO  - Failed to add virtual directory for cf_scripts

2019-05-31 09:27:07 INFO  - Rolling back the changes because of the Lockdown failure

2019-05-31 09:27:07 INFO  - Removing the alias created for ColdFusion scripts

2019-05-31 09:27:08 INFO  - Successfully removed the alias created for ColdFusion scripts

2019-05-31 09:27:08 INFO  - Reverting back the service logon users for ColdFusion services

2019-05-31 09:27:08 INFO  - The ColdFusion 2018 Add-on Services service is not started.

 

**There are more log entries about reverting and rolling back, but I didn't want to overload the post. I included a lot of the success entries at the top to provide context.

Coldfusion 11 on Mac OSX 10.14.5 not starting

$
0
0

Just had to restart my Mac server for the first time since Mac OSX upgrade from 10.14.4 to 10.14.5 last week.  ColdFusion now no longer starts.   Error log shows.

 

INFO: CFMxmlServlet: Macromedia Flex Build: 87315.134646

Jun 02, 2019 11:50:11 AM org.apache.coyote.AbstractProtocol start

INFO: Starting ProtocolHandler ["ajp-bio-8014"]

Jun 02, 2019 11:50:11 AM com.adobe.coldfusion.launcher.Launcher run

INFO: Server startup in 4859990 ms

Error: Could not load mediaLib accelerator wrapper classes. Continuing in pure Java mode.

Occurs in: com.sun.media.jai.mlib.MediaLibAccessor

com.sun.media.jai.mlib.MediaLibLoadException

Jun 02, 2019 12:02:58 PM org.apache.catalina.core.AprLifecycleListener lifecycleEvent

INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /Applications/ColdFusion11/cfusion/bin/../lib:/Applications/ColdFusion11/cfusion/bin/../l ib:

Jun 02, 2019 12:03:20 PM org.apache.coyote.AbstractProtocol init

INFO: Initializing ProtocolHandler ["ajp-bio-8014"]

Jun 02, 2019 12:03:21 PM org.apache.catalina.core.StandardService startInternal

INFO: Starting service Catalina

Jun 02, 2019 12:03:21 PM org.apache.catalina.core.StandardEngine startInternal

INFO: Starting Servlet Engine: Apache Tomcat/7.0.90

Jun 02, 2019 12:03:29 PM org.apache.catalina.startup.TldConfig execute

INFO: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.

Jun 02, 2019 12:03:30 PM org.apache.catalina.util.SessionIdGeneratorBase createSecureRandom

WARNING: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [135] milliseconds.

Jun 02, 2019 12:03:51 PM sun.misc.ObjectInputFilter$Config lambda$static$0

INFO: Creating serialization filter from !org.mozilla.**;!com.sun.syndication.**;!org.apache.commons.beanutils.**

Jun 02, 2019 12:03:53 PM org.apache.catalina.core.ApplicationContext log

INFO: ColdFusionStartUpServlet: ColdFusion: Starting application services

Jun 02, 2019 12:03:53 PM org.apache.catalina.core.ApplicationContext log

INFO: ColdFusionStartUpServlet: ColdFusion: VM version = 25.172-b11

 

Anyone else have this problem.  I am assuming it might have something to do with SHA1 no longer supported. ColdFusion server was fully patched to the latest release as of last week.  Anyone else running ColdFusion on Mac OSX having this issue?

CFC edit causing ColdFusion 2016 to crash

$
0
0

We have a test server running CF2016 with code migrated from CF10.

 

Everything works great... until... we pull a change from our repo that includes an edit to one of our CFC's.

 

We have a chain of CFC's that extend one another... on a server restart, it takes approximately 40 seconds for the CFC chain to init.  It takes a bit of time, but there are no issues.

 

If we make a single change to one of the CFCs in this chain on CF2016, it appears to be causing CF to "re-init" the entire chain and brings the server to a grinding halt under load.

 

When we do the exact same thing on CF10, it handles it like a pro.

 

I would love any suggestion on what to try here.  We've tried playing with various settings, but it seems there's something different in CF2016 that we are not aware of.

 

You help is greatly appreciated!

Viewing all 5794 articles
Browse latest View live