Club Delphi  
    FTP   CCD     Buscar   Trucos   Trabajo   Foros

Retroceder   Foros Club Delphi > Principal > Internet
Registrarse FAQ Miembros Calendario Guía de estilo Temas de Hoy

Grupo de Teaming del ClubDelphi

Respuesta
 
Herramientas Buscar en Tema Desplegado
  #1  
Antiguo 18-06-2021
tejano tejano is offline
Miembro
 
Registrado: dic 2020
Posts: 129
Poder: 4
tejano Va por buen camino
Cita:
Empezado por luismartin Ver Mensaje
Hola tejano. He intentado la prueba por línea de comandos, teniendo ya generado el gzip, en un fichero llamado lroe_1624012540.gz, pero me da problemas . Por lo visto, algo del certificado, pero parece más cosa del certificado del servidor (lógicamente, he ocultado datos sensibles):

Código:
$ curl --insecure --cert-type P12 --cacert cert_certFNMTEmpresa.pfx --pass contraseña -H "Accept-Encoding:gzip" -H "Content-Encoding:gzip" -H "Content-Type:application/octet-stream" -H "eus-bizkaia-n3-version:1.0" -H "eus-bizkaia-n3-content-type:application/xml" -H "eus-bizkaia-n3-data:{\"con\":\"LROE\",\"apa\":\"1.1\",\"inte\":{\"nif\":\"BXXXXXXXX\",\"nrs\":\"NOMBRE EMPRESA\"},\"drs\" :{\"mode\":\"240\",\"ejer\":\"2021\"}}" -v "https://pruesarrerak.bizkaia.eus/N3B4001M/kontsulta" --data-binary lroe_1624012540.gz --output respuesta.gz -D cabeceras_respuesta.txt
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0*   Trying 80.245.2.232...
* TCP_NODELAY set
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* Connected to pruesarrerak.bizkaia.eus (80.245.2.232) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* error setting certificate verify locations, continuing anyway:
*   CAfile: cert_certFNMTEmpresa.pfx
  CApath: none
} [5 bytes data]
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
} [512 bytes data]
* TLSv1.3 (IN), TLS handshake, Server hello (2):
{ [81 bytes data]
* TLSv1.2 (IN), TLS handshake, Certificate (11):
{ [4450 bytes data]
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
{ [527 bytes data]
* TLSv1.2 (IN), TLS handshake, Request CERT (13):
{ [36 bytes data]
* TLSv1.2 (IN), TLS handshake, Server finished (14):
{ [4 bytes data]
* TLSv1.2 (OUT), TLS handshake, Certificate (11):
} [7 bytes data]
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
} [134 bytes data]
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
} [1 bytes data]
* TLSv1.2 (OUT), TLS handshake, Finished (20):
} [16 bytes data]
* TLSv1.2 (IN), TLS handshake, Finished (20):
{ [16 bytes data]
* SSL connection using TLSv1.2 / DHE-RSA-AES256-GCM-SHA384
* ALPN, server did not agree to a protocol
* Server certificate:
*  subject: jurisdictionC=ES; jurisdictionST=BIZKAIA; jurisdictionL=BILBAO; businessCategory=Government Entity; postalCode=48009; C=ES; ST=BIZKAIA; L=BILBAO; street=GRAN V�A 25; O=BIZKAIKO FORU ALDUNDIA - DIPUTACION FORAL DE BIZKAIA; OU=IT; serialNumber=P4800000D; CN=pruesarrerak.bizkaia.eus
*  start date: Jul  3 12:41:06 2020 GMT
*  expire date: Jul  3 12:41:06 2022 GMT
*  issuer: C=ES; O=IZENPE S.A.; OU=BZ Ziurtagiri publikoa - Certificado publico EV; CN=CA de Certificados SSL EV
*  SSL certificate verify result: unable to get local issuer certificate (20), continuing anyway.
} [5 bytes data]
> POST /N3B4001M/kontsulta HTTP/1.1
> Host: pruesarrerak.bizkaia.eus
> User-Agent: curl/7.64.0
> Accept: */*
> Accept-Encoding:gzip
> Content-Encoding:gzip
> Content-Type:application/octet-stream
> eus-bizkaia-n3-version:1.0
> eus-bizkaia-n3-content-type:application/xml
> eus-bizkaia-n3-data:{"con":"LROE","apa":"1.1","inte":{"nif":"BXXXXXXXX","nrs":"NOMBRE EMPRESA"},"drs" :{"mode":"240","ejer":"2021"}}
> Content-Length: 18
> 
} [18 bytes data]
* upload completely sent off: 18 out of 18 bytes
* OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 104
100    18    0     0  100    18      0     68 --:--:-- --:--:-- --:--:--    68
* Closing connection 0
curl: (56) OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 104
Como decía, lroe_1624012540.gz es donde tengo el gzip conteniendo el XML del LROE (que a su vez contiene la factura TBAI)
En tu caso creo que el certificado no es P12, es pfx. Puede ser que vaya por ahí la cosa.

Saludos
Responder Con Cita
Respuesta



Normas de Publicación
no Puedes crear nuevos temas
no Puedes responder a temas
no Puedes adjuntar archivos
no Puedes editar tus mensajes

El código vB está habilitado
Las caritas están habilitado
Código [IMG] está habilitado
Código HTML está deshabilitado
Saltar a Foro

Temas Similares
Tema Autor Foro Respuestas Último mensaje
SII -Nuevo sistema de la Agencia Tributaria española de envío de datos vía Webservice newtron Internet 3565 Hace 1 Semana 11:04:13
Como utilizar la ayuda del nuevo Sistema Operativo gluglu Humor 3 24-09-2007 09:39:05
Aplicacion Agencia De Viajes ArdiIIa Varios 9 20-01-2007 16:49:53
El Vasco Aguirre Al González La Taberna 5 26-05-2006 09:22:28
Microsoft ha lanzado su nuevo sistema operativo DarkByte Humor 0 25-01-2004 09:21:14


La franja horaria es GMT +2. Ahora son las 08:45:26.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi
Copyright 1996-2007 Club Delphi