MSSQL Login failed. The login is from an untrusted domain

I have been reading a lot about this error, but am not having luck.

"Login failed. The login is from an untrusted domain and cannot be used with Windows authentication.

I am attempting to manually insert a value to a MSSQL database that is on our network. I have the correct username and password and it is authorized to make changes to the db.

I am using the node-red-mssql-contrib-plus node for this.

I do not need Windows authentication for what I am trying to do.

[{"id":"ffde55a9.6d2f5","type":"debug","z":"de6edb87.f9a34","name":"","active":false,"tosidebar":true,"console":false,"complete":"payload","x":1150,"y":280,"wires":[]},{"id":"2b205631.570662","type":"MSSQL","z":"de6edb87.f9a34","mssqlCN":"ffadf3a7.5a25c8","name":"MSSQL","query":"","outField":"payload","returnType":"0","throwErrors":"0","x":919,"y":281,"wires":[["ffde55a9.6d2f5"]]},{"id":"127b67a.7b25218","type":"inject","z":"de6edb87.f9a34","name":"Insert","topic":"","payload":"INSERT INTO [X] (temp) VALUES (8)","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":"","x":630,"y":280,"wires":[["2b205631.570662"]]},{"id":"ffadf3a7.5a25c8","type":"MSSQL-CN","z":"","tdsVersion":"7_4","name":"XXXX","server":"XXXX","port":"XXXX","encyption":false,"database":"XXX","useUTC":true,"connectTimeout":"15000","requestTimeout":"15000","cancelTimeout":"5000","pool":"5"}]

Your sample flow shows you're trying to connect to server xxxxxx is this intended or have you sanitised the export?

Sanitized the export.

Just re-read this. Are you using windows credentials? Do you have a SQL account you can test with?

As a test, can you connect to the SQL server using another application (ideally from the node-red machine) to verify access and verify SQL type login are possible?

So when I switched to node-red-mssql-contrib-plus from node-red-mssql-contrib I did not retest leaving the domain blank. When I removed the Domain field this issue went away. The sql instance and node red instance are on the same app server.

It also sat over the weekend running so maybe the good type of gremlins helped me out (you know...before you feed them)

1 Like