TLS 1.2 CT-e 3.0 and NF-e 4.0 protocol

Asked

Viewed 1,486 times

0

I am developing CT-e 3.0 and NF-e 4.0, in the same cites the need to change the security protocol from SSL to TLS 1.2 with the deadline of 02/04/2018.

In the reception webservice has no information about the protocols, the documentation of both (CT-e and NF-e), leaves a little vague the changes that are necessary.

the application is developed in c# and VB.NET.

Because of this, I searched for implementations on the internet arriving at the following implementation: ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 Or SecurityProtocolType.Ssl

Even implementing this we had no differences and also could not perform the test to know if it is only this change that should be made or if the change should also be made in digital certificate and/ or chain of certificates.

We would like to make sure that these are the only necessary changes?

If you have something more to implement, I would like the contribution of the community.

Note: We use A1 and A3 Certificate.

  • I believe that’s all it is, but you just happened to come to some different conclusion?

1 answer

3


I took the following test:

I used an app to check SEFAZ MG status in the . NET Framework 2.0 approval environment, without changing the protocol to TLS 1.2.

I opened Wireshark and activated a packet filter for TLS 1.2 protocol this way:

ssl.record.version == 0x0303

The result was that no package was displayed, IE, not transmitted with Protocol TLS 1.2.

Then I changed the code to use TLS 1.2. In . NET 2.0, there is no constant in the enumeration, but it is possible to do the equivalent as follows:

System.Net.ServicePointManager.SecurityProtocol = (SecurityProtocolType)3072;

When running the application with this change, Wireshark displayed packets account for an SEFAZ IP with TLS 1.2 protocol.

inserir a descrição da imagem aqui

Conclusion: This is the only amendment needed.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.