Facing issue in Teamcenter extension

0
Hi,   Im getting below error while opening teamcenter extension in studio pro after taking latest pull changes from the team server.   System.Security.Cryptography.CryptographicException: Padding is invalid and cannot be removed.   at System.Security.Cryptography.SymmetricPadding.GetPaddingLength(ReadOnlySpan`1 block, PaddingMode paddingMode, Int32 blockSize)   at System.Security.Cryptography.UniversalCryptoDecryptor.UncheckedTransformFinalBlock(ReadOnlySpan`1 inputBuffer, Span`1 outputBuffer)   at System.Security.Cryptography.UniversalCryptoDecryptor.UncheckedTransformFinalBlock(Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount)   at System.Security.Cryptography.UniversalCryptoTransform.TransformFinalBlock(Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount)   at System.Security.Cryptography.CryptoStream.ReadAsyncCore(Memory`1 buffer, CancellationToken cancellationToken, Boolean useAsync)   at System.Security.Cryptography.CryptoStream.Read(Byte[] buffer, Int32 offset, Int32 count)   at System.IO.StreamReader.ReadBuffer()   at System.IO.StreamReader.ReadToEnd()   at Mendix.TeamcenterExtension.FileHelper.DecryptString(String encryptedText, Byte[] encryptionKey) in C:\Mx\Teamcenter Toolkit-release-candidate-3.2\extensibilitysource\Mendix.TeamcenterExtension\Resources\FileHelper.cs:line 90   at Mendix.TeamcenterExtension.VersionMigrator.<>c.<CreateMigrationHelpersFromDisk>b__3_0(String filePath) in C:\Mx\Teamcenter Toolkit-release-candidate-3.2\extensibilitysource\Mendix.TeamcenterExtension\Resources\VersionMigrator\VersionMigrator.cs:line 50   at System.Linq.Enumerable.SelectListIterator`2.MoveNext()   at System.Linq.Enumerable.OfTypeIterator[TResult](IEnumerable source)+MoveNext()   at System.Linq.Enumerable.WhereEnumerableIterator`1.ToList()   at Mendix.TeamcenterExtension.VersionMigrator.JourneyMigrations() in C:\Mx\Teamcenter Toolkit-release-candidate-3.2\extensibilitysource\Mendix.TeamcenterExtension\Resources\VersionMigrator\VersionMigrator.cs:line 21   at Mendix.TeamcenterExtension.TeamcenterMenuExtension.OpenDialogReact() in C:\Mx\Teamcenter Toolkit-release-candidate-3.2\extensibilitysource\Mendix.TeamcenterExtension\TeamcenterMenuExtension.cs:line 63   at Mendix.Modeler.Controls.Menus.MenuItemViewModel.<>c__DisplayClass12_0.<.ctor>b__0() in Mendix.Modeler.Controls\Menus\MenuItemViewModel.cs:line 29   at Mendix.Modeler.Core.View.Menus.MainMenu.ExecuteMenuItem(IMenuItemViewModel menuItemViewModel) in Mendix.Modeler.Core.View\Menus\MainMenu.cs:line 248   I have tried with reimporting teamcenter connector and extension module, but didn't work.   It would be really helpful, to give some solution.   Thanks in advance.    
asked
3 answers
1

Hi Imthiyaz,

 

It seems there are files (generated integrations and your Teamcenter configuration) in your usr folder (located in your project folder at resources\TeamcenterExtension\usr) which were encrypted with a different key then your current encryption key in the usr folder.

 

This can happen when the extension is used for the first time with two people at the same time and they both commit their changes. A key file is created when your open the extension for the first time. Your configuration and generated integrations are encrypted with this encryption key,

 

This can also happen if files were moved from one project's usr folder to another project's in a way there are now two sets of files encrypted by different encryption keys.

 

There is a way to get rid of this error, but unfortunately you will lose your current generated history (generated microflows and entities will stay in your model). Go to your project folder navigate to resources\TeamcenterExtension and delete the usr folder. Then open the extension again and commit your changes. Then all developers share the same key after pulling.

 

Thanks for your feedback on this issue. We'll look into approaches to avoid this situation in future releases.

answered
0

Hi Remco,

 

Thanks a lot this workaround is working fine.

 

One more thing previously we faced teamcenter connection issue from mendix, we couldn't able to connect to teamcenter it shows HTTP 400 error. 

I tried a workaround by reverting a commit and try to reimport all the modules this worked, but it becomes a rework for our team members. so could you pls suggest a solution on why this issue happened and how to resolve this if this occurs.

 

Thank you once again.

answered
0

Hi Remco Mul,

I'm facing an teamcenter extension conflict issue while taking the latest pull. I'm not sure how to resolve this issue since this is file conflict issue , could you please give your valuable suggestion to resolve this. 

Many of my colleagues also facing this file conflict issue from teamcenter extension. It would be really helpful of any solution to this.

 

Conflict path : resources/TeamcenterExtension/usr/tc_configuration.json

 

 

 

Thanks,

Imthiyaz

answered