Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


devonway
2012-10-03T20:55:20Z
One of our regularly run tasks (Trn_Log_Backup_Dict) failed with the below error. We see this error intermittently and not sure what causes it.
Rerun of this task was successful within 30 minutes. This is a critical SQL task that needs to run every 30 minutes for our database backups. We are on version 6.1.2.

10/3/2012 12:55:39 PM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.

at System.Security.Cryptography.CryptographicException.ThrowCryptogaphicException(Int32 hr)
at System.Security.Cryptography.Utils._AcquireCSP(CspParameters param, SafeProvHandle& hProv)
at System.Security.Cryptography.Utils.AcquireProvHandle(CspParameters parameters)
at System.Security.Cryptography.CryptoAPITransform..ctor(Int32 algid, Int32 cArgs, Int32[] rgArgIds, Object[] rgArgValues, Byte[] rgbKey, PaddingMode padding, CipherMode cipherChainingMode, Int32 blockSize, Int32 feedbackSize, Boolean useSalt, CryptoAPITransformMode encDecMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider._NewEncryptor(Byte[] rgbKey, CipherMode mode, Byte[] rgbIV, Int32 feedbackSize, CryptoAPITransformMode encryptMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider.CreateDecryptor(Byte[] rgbKey, Byte[] rgbIV)
at OBOKIIHBDBPMCFALPGECCIFHCDJPEDKODDGK.IIENJEFNGNBNNKBDBGFBGEPAKLDBJPHECBLI.ILNMENNFFOACJGFEIAPJFNNIGJJGFLDMEKEC(Byte[] )
10/3/2012 12:55:39 PM Err Exception in Task: The ConnectionString property has not been initialized.
10/3/2012 12:55:39 PM Info Task completed: Trn_Log_Backup_Dict (43887)
Sponsor
Forum information
Support
2012-10-04T06:22:56Z
There seems to be some kind of value that has been altered resulting in that decryption of that value (before execute) is failing. Try editing the SQL Task and confirm that a Connection is selected and also save the Task. Then try to run the Task again.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
devonway
2012-10-04T21:19:25Z
Hi Henrik,

This just happened again on a different database. I confirmed that the sql connection has been selected for all database tasks. Rerun is always successful so this is an intermittent problem. We have not seen this error on our test database server so we are not sure how to reproduce the error conditions.

10/4/2012 3:55:40 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.

at System.Security.Cryptography.CryptographicException.ThrowCryptogaphicException(Int32 hr)
at System.Security.Cryptography.Utils._AcquireCSP(CspParameters param, SafeProvHandle& hProv)
at System.Security.Cryptography.Utils.AcquireProvHandle(CspParameters parameters)
at System.Security.Cryptography.CryptoAPITransform..ctor(Int32 algid, Int32 cArgs, Int32[] rgArgIds, Object[] rgArgValues, Byte[] rgbKey, PaddingMode padding, CipherMode cipherChainingMode, Int32 blockSize, Int32 feedbackSize, Boolean useSalt, CryptoAPITransformMode encDecMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider._NewEncryptor(Byte[] rgbKey, CipherMode mode, Byte[] rgbIV, Int32 feedbackSize, CryptoAPITransformMode encryptMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider.CreateDecryptor(Byte[] rgbKey, Byte[] rgbIV)
at OBOKIIHBDBPMCFALPGECCIFHCDJPEDKODDGK.IIENJEFNGNBNNKBDBGFBGEPAKLDBJPHECBLI.ILNMENNFFOACJGFEIAPJFNNIGJJGFLDMEKEC(Byte[] )
10/4/2012 3:55:40 AM Err Exception in Task: The ConnectionString property has not been initialized.
10/4/2012 3:55:40 AM Info Task completed: Trn_Log_Backup_DWAY2 (50421)

Any help is appreciated.

Thanks,
DevonWay
Support
2012-10-05T06:27:32Z
Ok, please let us know the exact settings you use for the connection. What database? Is it OLEDB,ODBC or direct? Please send screenshots to support@visualcron.com

Please also export your settings to us and tell us the Job and Task name that fails.

Another thing I am thinking about is the actual SQL string that you use. It might me some kind of characters in the string that messes things up. Just an idea that maybe you should clean up the string or try a different one. Perhaps even better to put the SQL as a stored procedure - just for testing at least.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
devonway
2012-10-12T22:05:44Z
Hi Henrik,

We sent out the information on 10/12/2012 1:56 PM PDT through email to support@visualcron. Please let us know if you need anything else.

Thanks,
DevonWay
Support
2012-10-15T12:06:24Z
Another thing I am thinking about is the actual SQL string that you use. It might me some kind of characters in the string that messes things up. Just an idea that maybe you should clean up the string or try a different one. Perhaps even better to put the SQL as a stored procedure - just for testing at least.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
devonway
2012-11-14T19:48:18Z
This type of error just happened on one of our other production servers (on version 6.1.2):

11/14/2012 2:55:47 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.

at System.Security.Cryptography.CryptographicException.ThrowCryptogaphicException(Int32 hr)
at System.Security.Cryptography.Utils._AcquireCSP(CspParameters param, SafeProvHandle& hProv)
at System.Security.Cryptography.Utils.AcquireProvHandle(CspParameters parameters)
at System.Security.Cryptography.CryptoAPITransform..ctor(Int32 algid, Int32 cArgs, Int32[] rgArgIds, Object[] rgArgValues, Byte[] rgbKey, PaddingMode padding, CipherMode cipherChainingMode, Int32 blockSize, Int32 feedbackSize, Boolean useSalt, CryptoAPITransformMode encDecMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider._NewEncryptor(Byte[] rgbKey, CipherMode mode, Byte[] rgbIV, Int32 feedbackSize, CryptoAPITransformMode encryptMode)
at System.Security.Cryptography.TripleDESCryptoServiceProvider.CreateDecryptor(Byte[] rgbKey, Byte[] rgbIV)
at OBOKIIHBDBPMCFALPGECCIFHCDJPEDKODDGK.IIENJEFNGNBNNKBDBGFBGEPAKLDBJPHECBLI.ILNMENNFFOACJGFEIAPJFNNIGJJGFLDMEKEC(Byte[] )

It is not clear which job is associated with this error. Can you tell us which type of task could throw this error?

It would be great for troubleshooting if each error was printed with the corresponding task id or job id.
Support
2012-11-14T20:12:57Z
This error is not related to any Task but to decryption in general. For example, decrypting passwords that are used in Credentials etc.

Again, these are errors I have not seen before and the *should* not occur. I really wonder what causes these errors.

We use 3DES encryption/decryption here and I wonder if it is .NET update that has gone wrong or if there is a policy change or any encryption related change on your servers.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
devonway
2012-11-29T23:28:44Z
We have not had any problems with .NET update or encryption related change or a policy change on our servers. Here is a list of occurrences:

Server1:
11/25/2012 8:30:37 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/25/2012 12:55:40 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/24/2012 1:30:39 PM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.
11/24/2012 1:20:34 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/19/2012 1:31:36 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.
11/15/2012 10:56:00 PM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/15/2012 2:26:00 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/13/2012 3:56:00 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.
11/11/2012 11:48:51 PM Err Decryption failed: System.Security.Cryptography.CryptographicException: Provider type not defined.
11/8/2012 5:56:00 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.
11/8/2012 1:55:39 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.

Server2:
11/14/2012 2:55:47 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.

On Server2, this error does correspond to IIS DefaultAppPool recycle, but not on Server1. Sine this is our production area, we page the oncall staff everytime we get this failure, so this is a critical issue for us even if it happens once a week or so.

Thanks,
DevonWay
Support
2012-11-30T09:13:30Z
Searched google and the problem seems to be some kind of restriction of folders in your case:

Cconfigure the MachineKeys folder sercurities and give the user Read & Execute, List Folder Contents, Read, Write. If that doesn't work, try giving the Everyone user the same permissions. The user that needs access is the SYSTEM account unless you changed the user that runs the VisualCron service.

Normally, this folder is located here:

C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\MachineKeys
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
bbusse
2012-11-30T15:19:37Z
Originally Posted by: Support 

Normally, this folder is located here:

C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\MachineKeys




Depending on your OS, this is true. On Server 2008 R2, I'm finding the folder is located here:

C:\ProgramData\Microsoft\Crypto\RSA\MachineKeys

You should see 2 groups with permissions by default. Everyone, and Administrators. From the normal view, you won't see the permissions, but if you scroll down you'll see 'special' checked. Dig in a little, and you'll see that allow is given to several options. Make sure your system has permissions for whatever user is running the VisualCron service. "NT AUTHORITY\SYSTEM" or just "SYSTEM" is the default, unless you changed the ID. I can't remember if 'SYSTEM' is considered part of the Everyone group... so you may want to try adding 'SYSTEM' with the same permissions I show for the Everyone group.

Brian
File Attachment(s):
11-30-2012 9-16-31 AM.jpg (308kb) downloaded 90 time(s).
Support
2012-12-01T09:42:29Z
Yes, SYSTEM is part of that group. This resolution was just a hunch as it was resolved that way by another user. The actual error is not really part of VisualCron but comes on a lower level were some component fails to retrieve the information needed. Searching on the error and we see various resolutions. Not sure how to go from here but I am sure that you will not have this problem on a fresh installed Windows. There is some kind of setting that has applied generally after install.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
devonway
2012-12-04T02:09:17Z
Hi Henrik,

Turns out we have already tried this fix but that didn't make a difference. Sorry should have posted earlier in this thread.

Thanks,
DevonWay
devonway
2012-12-06T00:34:56Z
Hi Henrik,

Actually, we were missing the write permission for the system account so we added that on Friday but we still got this error this morning:

12/5/2012 8:55:40 AM Err Decryption failed: System.Security.Cryptography.CryptographicException: Keyset as registered is invalid.


Thanks,
DevonWay
Support
2012-12-06T08:01:34Z
Right now I am out of ideas if you cannot find anything more on google on this. I am not sure if this is a security error or configuration error. I think you need to go the route with a vanilla install of the OS.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top