aws / aws/sagemaker-python-sdk
Support custom SSL certificate bundles
- Lenguaje dominante
- Python
- Estrellas
- 2.3k
- Forks
- 1.3k
- Merge medio
- 1 d 22 h
- PR fusionados (30 d)
- 35
Descripción
**Describe the feature you'd like**
Support custom SSL verification control in SageMaker Python SDK.
`Boto3` supports the [verify](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/core/session.html#boto3.session.Session.client) parameter when creating a client, which allows either disabling SSL verification or setting a custom certificate bundle. Alternatively, a custom certificate bundle can be set through the `config` file or by the `AWS_CA_BUNDLE` environment variable.
However, these are not exposed or respected by the SageMaker Python SDK. This prevents SageMaker code from being used behind some corporate firewalls.
The lack of this feature has been noted in https://github.com/aws/sagemaker-python-sdk/discussions/3656
**How would this feature be used? Please describe.**
Corporate firewalls may re-encrypt an SSL connection with their own certificate. Unless this certificate is configured as a root certificate, SSL verification fails. This change will allow use of the SageMaker Python SDK behind such MITM-based firewalls.
**Describe alternatives you've considered**
N/A
**Additional context**
The specific error raised by SageMaker:
```
SSLError: SSL validation failed for https://sts.us-west-2.amazonaws.com/ [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1147)
```
Guía de contribución
Línea de trabajo
Comienza localizando cómo el SDK crea clientes de Boto3 y cómo se transmiten las configuraciones de sesión o de config. Compara esos puntos de entrada con el parámetro verify de Boto3 y el comportamiento de AWS_CA_BUNDLE. Se considera terminado cuando los llamadores pueden controlar la verificación SSL o usar un bundle de certificados personalizado, con tests que cubran las rutas de configuración compatibles.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- aws, python
- Área
- cloud, security
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100