Title:
Administrator API setMySQL5() throws error if user is logged into a ColdFusion application
| View in TrackerStatus/Resolution/Reason: Closed/Withdrawn/Duplicate
Reporter/Name(from Bugbase): Mikel Goicoechea / Mikel Goicoechea (Mikel Goicoechea)
Created: 11/23/2016
Components: Administrator
Versions: 2016
Failure Type:
Found In Build/Fixed In Build: CF2016_Update3 / 4199061
Priority/Frequency: Major / All users will encounter
Locale/System: English / Win 2012 Server x64
Vote Count: 1
Problem Description: cfide.adminapi.datasource.setMySQL5() only works if the user is not logged into a ColdFusion application
Steps to Reproduce:
run this script:
<!--- log user into cf application --->
<cfloginuser name="test" password="" roles="">
<!--- log into cf administrator --->
<cfset administrator = CreateObject("component","cfide.adminapi.administrator")>
<cfset loginSuccess = administrator.login("test")><!--- add actual credentials --->
<!--- create datasource parameters --->
<cfset datasourceValues = StructNew()>
<cfset datasourceValues.host = "test">
<cfset datasourceValues.database = "test">
<cfset datasourceValues.name = "test">
<cfset datasourceValues.password = "test">
<cfset datasourceValues.username = "test">
<!--- create datasource --->
<cfset datasource = CreateObject("component","cfide.adminapi.datasource")>
<cfset datasource.setMySQL5(argumentCollection=datasourceValues)>
Actual Result:
ColdFusion error: coldfusion.security.SecurityManager$UnauthenticatedCredentialsException
Expected Result:
datasource created
Any Workarounds:
log the user out with <cflogout> before calling setMySQL5()
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 4198041
External Customer Info:
External Company:
External Customer Name: Mikel Goicoechea
External Customer Email:
External Test Config: My Hardware and Environment details:
We're running ColdFusion 2016 on Windows Server 2012, but I don't think it matters.
Attachments:
Comments: