Unable to connect Netapp (8.1.4P1 7-Mode) with jdk1.8.0_181 - storage

We have below security configuration at storage side (8.1.4P1 7-Mode)
Configurations
tls.enable on
ssl.enable on
ssl.v2.enable off
ssl.v3.enable off
We tried to access storage using NetApp Manageability SDK 5.7 and it is working fine with jdk1.8.0_161.
We upgrade JDK to jdk1.8.0_181 and then we are not able to access it, Its throwing Exception
`2018-08-03 05:06:27,071 [Thread-1469] app-ERROR-javax.net.ssl.SSLException: Connection has been shutdown: `javax.net.ssl.SSLHandshakeException`: Received fatal alert: handshake_failure at` `sun.security.ssl.SSLSocketImpl.checkEOF(SSLSocketImpl.java:1551)`
at sun.security.ssl.AppInputStream.read(AppInputStream.java:95)
at sun.security.ssl.AppInputStream.read(AppInputStream.java:71)
at netapp.manage.http.HTTPMessage.readLine(HTTPMessage.java:245)
at netapp.manage.http.HTTPResponse.read(HTTPResponse.java:74)
at netapp.manage.http.HTTPClient.doRequest(HTTPClient.java:772)
at netapp.manage.NaServer.invokeHTTP(NaServer.java:955)
As per release notes of jdk "jdk1.8.0_181", JDK 181 disabled "3DES cipher suites".
Is there any way to fix it from NetApp side ?

While not an answer to the direct question of how to solve this from the NetApp side, the problem can be overcome on the application side by removing "3DES_EDE_CBC" from the jdk.tls.disabledAlgorithms security property at runtime. Something like:
final String JDK_TLS_DISABLED_ALGORITHMS = "jdk.tls.disabledAlgorithms";
final String TRIPLE_DES_EDE_CBC = "3DES_EDE_CBC";
final String disabledAlgorithms = Splitter.on(',').trimResults()
.splitToList(Security.getProperty(JDK_TLS_DISABLED_ALGORITHMS)).stream()
.filter(algo -> !algo.equals(TRIPLE_DES_EDE_CBC)).collect(joining(", "));
Security.setProperty(JDK_TLS_DISABLED_ALGORITHMS, disabledAlgorithms);

Related

#ActiveProfiles in Spring Test does not support placeholders any longer

I am upgrading from Spring 4.3 to Spring 5.3 and it seems that placeholders are no longer supported for the #ActiveProviles annotation.
The following code worked with the old Spring version:
#RunWith(SpringRunner.class)
#SpringBootTest
#ActiveProfiles({"${profileA}","someProfileWithoutPlaceholders"})
#ContextConfiguration(classes = MyApplication.class)
public class MyTest {...}
But it stopped working with the upgrade and now it get
Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'nucleus.hibernate.dialect' in value "${nucleus.hibernate.dialect}"
at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:178)
at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:124)
at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:239)
at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:210)
at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.lambda$processProperties$0(PropertySourcesPlaceholderConfigurer.java:175)
at org.springframework.beans.factory.support.AbstractBeanFactory.resolveEmbeddedValue(AbstractBeanFactory.java:936)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1321)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:640)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:399)
... 55 more
Note, that 'nucleus.hibernate.dialect' is defined in the application properties referenced by "${profileA}".
As a workaround, I tried to specify the properties as test property source explicitly using
#TestPropertySource(locations={"classpath:/application-${profileA}.properties"}})
and that works.
I am not sure if using placeholders for selecting a Spring profile on a Spring integration test is an officially supported feature. If yes, I consider this a breaking change in the Spring test framework.
After debugging around the test case I got a bit more insight on this issue.
It seems that in
org.springframework.core.env.PropertySourcesPropertyResolver#getProperty(java.lang.String, java.lang.Class<T>, boolean)
the test property source 'test' splits up the profiles and has two entries:
spring.profiles.active[0] -> "${profileA}
spring.profiles.active[1] -> "someProfileWithoutPlaceholders"
So when looking up with key "spring.profiles.active", it does not find any value, and org.springframework.core.env.AbstractPropertyResolver#resolveNestedPlaceholders is not called.
This is done in org.springframework.core.env.AbstractEnvironment#doGetActiveProfiles when building the test application context..
In the old Spring version, there was only one map entry:
spring.profiles.active -> "${profileA},someProfileWithoutPlaceholders"
so it found the entry and resolved the placeholder.

Unsupported Java encoding for writing wsdl file

when deploying the following webservice
#WebService(serviceName = "TestService")
#SOAPBinding(use = Use.LITERAL, style = Style.DOCUMENT, parameterStyle= SOAPBinding.ParameterStyle.WRAPPED)
public class KekeDummyWebservice implements kekeService {...
on one of my servers I do get the following error:
javax.wsdl.WSDLException: WSDLException:faultCode=CONFIGURATION_ERROR: Unsupported Java encoding for writing wsdl file: 'ISO8859_15'.
I don't know where the 'ISO8859_15' encoding comes from. The wildfly prints out
-Dfile.encoding=ISO-8859-15
while starting. Another point is that during wildfly start the warning
[jacorb.codeset] (MSC service thread 1-7) Warning - unknown codeset (ISO8859_15) - defaulting to ISO-8859-1
can be seen.
Thanks
I had similar issue on our system, with following error in the log during deployment on Wildlfy10:
Caused by: javax.wsdl.WSDLException: WSDLException: faultCode=CONFIGURATION_ERROR: Unsupported Java encoding for writing wsdl file: 'Cp1252'
Finally it was solved by resaving of xsd/wsld in utf-8 and setting targetNamespace in WS implementaion accordingly to what was defined in xsd/wsld. This aproach is not fully applicable on your case, but maybe it helps.
Try to run command "locale". It will give "LANG=en_US.ISO-8859-15".
Update this LANG to use "en_US.UTF-8" using export.
This solved the issue.

dotnetopenauth samples "Attempt by method 'DotNetOpenAuth.OAuth2.WebServerClient ..."

I've just been spending hours on an issue that some others have reported to experience too.
The Sample.Oauth2.OAuthClient projet sample does not work for me.
Let me explain in details:
I got the latest version of dotnetopenauth from github (december 12th)
I ensured to "unblock" the zip before extracting all files.
I opened the solution with VS2012 (under Win7)
When starting the
Sample.Oauth2.OAuthClient project,
the overall build process succeed.
The website is started.
When calling
Sign in with Facebook (OAuth 2.0)
I get
Attempt by method
'DotNetOpenAuth.OAuth2.WebServerClient+d__3.MoveNext()'
to access method
'System.Collections.Generic.List`1..ctor()' failed.
Line 106: // verifiable for the same user/session.
Line 107: // If the host is implementing the authorization tracker
though, they're handling this protection themselves.
Line 108: var cookies = new List();
Line 109: if (this.AuthorizationTracker
== null) {
Line 110: string xsrfKey =
MessagingUtilities.GetNonCryptoRandomDataAsBase64(16, useWeb64: true);
That the provided code is not able to access "System.Collections.Generic.List" bewilders me...
I tried the following :
adding
<system.web>
<securityPolicy>
<trustLevel name="Full" policyFile="internal"/>
</securityPolicy>
to web.config.
Note that checking just before the line the "CurrentTrustLevel" results in "Unrestricted".
I tried to publish to local IIS 7,
tried running the pool under "administrator"
and finally
I tried with VS2013 on another, "clean" installation of Win7,
All attempts lead to the same result ...
It seems that the errors comes from some System.Net Dlls provided with the samples : they cannot be run by asp.net for security reasons (?)
Any idea ?

error in running transformation:indexoutofrangeexception - petapeco

as per suggestion for by #CreativeManix I started investigating petaPeco
Retrieving large number of rows (more than 10 mil) in asp.net mvc application
After adding exact system.data.oracleclient + putting web.config in the bin where mvc is getting compiled in .dll I got following error:
Error 3
Running transformation: System.IndexOutOfRangeException: Index was outside the bounds of the array.
at System.Array.InternalGetReference(Void* elemRef, Int32 rank, Int32* pIndices)
at System.Array.GetValue(Int32 index)
at Microsoft.VisualStudio.TextTemplating5F4490FB7AE018243DBB4DF6250E7211.GeneratedTextTransformation.GetCurrentProject()
at Microsoft.VisualStudio.TextTemplating5F4490FB7AE018243DBB4DF6250E7211.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName)
at Microsoft.VisualStudio.TextTemplating5F4490FB7AE018243DBB4DF6250E7211.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating5F4490FB7AE018243DBB4DF6250E7211.GeneratedTextTransformation.LoadTables()
at Microsoft.VisualStudio.TextTemplating5F4490FB7AE018243DBB4DF6250E7211.GeneratedTextTransformation.TransformText()
at Microsoft.VisualStudio.TextTemplating.TransformationRunner.RunTransformation(TemplateProcessingSession session, String source, ITextTemplatingEngineHost host, String& result)
This error shows up when i run the transformation after installation of petaPoco.
One thing I do know the error is coming from "GetCurrentProject" - and probably - "(Array)dte.ActiveSolutionProjects"
I think something is wrong in the way petaPoco is set up with my project! somehow it can't find the activesolution project. I am not too sure how to fix it.
I investigated this.
In my question section I asked few questions:
I was not sure about how to fire transformation/or process of generating Database.CS. So initially I was installing petapoco from the command prompt- I
To do that you just click "Run Custom Tool" by right clicking on the "Database.tt". If your connection string is correct + you are referencing correct Oracle/SQL server data provider + that provider is available in GAC + (if it is oracle and you have the password for the default schema user of the database you are trying to access)- then that should generate the Database.cs
To enable Oracle data client to read the schema out of oracle database I needed to take out following entry:
cmd.GetType().GetProperty("BindByName").SetValue(cmd, true, null);
And everything worked.
Connection string can look like:
connectionString="Data Source=PXWREG;Persist Security Info=True;User ID=XWREG_ACDS_T;password=isacdst"

Exception while calling stored procedure :Bigger type length than Maximum

HI I am getting this exception when I am calling any stored procedure from my J2EE app.
Exception while calling stored procedure :Bigger type length than Maximum
I am having Oracle 9.1.0.7, JDK1.4 and using ojdbc14.jar running on Weblogic 8.1
Please advise what could be the root cause ?
Below is the manifest of my ojdbc14.jar
Manifest-Version: 1.0
Implementation-Version: "Oracle JDBC Driver version - 10.1.0.2.0"
Specification-Title: "Oracle JDBC driver classes for use with JDK1.4"
Specification-Version: "Oracle JDBC Driver version - 10.1.0.2.0"
Implementation-Title: "ojdbc14.jar"
Created-By: 1.2.2 (Sun Microsystems Inc.)
Implementation-Time: "Wed Jan 21 00:48:12 2004"
Implementation-Vendor: "Oracle Corporation"
Specification-Vendor: "Oracle Corporation".
It's a driver bug. Your version is already 6 years old. Download the latest and greatest from here.
See this post for a possible workaround.
For possible causes, see this thread:
There are bugs in different versions
of the drivers and different versions
of the database; most of them are
fixed in later versions.
For example, bugs produce the "Bigger
type length than maximum" in Oracle
database 8.1.7.2 or 9.0.1.1 for
certain very specific operations using
DB links; upgrading to 8.1.7.3 or
8.1.7.4 or 9.0.1.2 resolves those problems.
For example, bugs produce the "Bigger
type length than maximum" in Oracle
database 10.1.0.2 and 10.1.0.3 for
certain very specific operations
involving NLS characters; upgrading to
10.1.0.4 pr 10.2.0.1 resolves those problems.
For example, the 8.1.6 classes12.zip
had such a bug on certain operation
with databases in a UNICODE character
set, that was fixed in the 8.1.7.4
driver.
If you have an Oracle support
contract, you can find out this
information on the Oracle support
site; metalink.oracle.com If not,
download the latest versions of the
drivers and pray...
i downloaded the latest driver and now much better - now that all the referenced locations are updated
Another option than you can consider is review your query parameters, specially setFetchSize, if its too high this error is returned.
java.sql.SQLException: Bigger type length than Maximum
There is a maximun size depending on the database in my case 64kb (Oracle) my highest value have to be 65535
Reference document:
https://docs.oracle.com/cd/E11882_01/java.112/e16548/resltset.htm#JJDBC28621

Resources