extrawest / extrawest_ocpi Goto Github PK
View Code? Open in Web Editor NEWPython implementation of Open Charge Point Interface (OCPI) protocol based on fastapi.
Home Page: https://www.extrawest.com/
License: MIT License
Python implementation of Open Charge Point Interface (OCPI) protocol based on fastapi.
Home Page: https://www.extrawest.com/
License: MIT License
Scanned /workspace/app/requirements.txt file as a requirements.txt and found 19 packages
+-------------------------------------+------+-----------+---------+---------+----------------------+
| OSV URL | CVSS | ECOSYSTEM | PACKAGE | VERSION | SOURCE |
+-------------------------------------+------+-----------+---------+---------+----------------------+
| https://osv.dev/GHSA-2jv5-9r88-3w3p | 7.5 | PyPI | fastapi | 0.101.1 | app/requirements.txt |
| https://osv.dev/PYSEC-2024-38 | | | | | |
+-------------------------------------+------+-----------+---------+---------+----------------------+
+==============================================================================+
VULNERABILITIES FOUND
+==============================================================================+
-> Vulnerability found in fastapi version 0.101.1
Vulnerability ID: 64930
Affected spec: <0.109.1
ADVISORY: FastAPI 0.109.1 addresses a critical security issue by
upgrading its dependency python-multipart to version >=0.0.7. The upgrade...
PVE-2024-64930
For more information, please visit
https://data.safetycli.com/v/64930/f17
Scan was completed. 1 vulnerability was found.
+==============================================================================+
To inform and ask for possibility to fix vulnerabilities?
extrawest_ocpi/py_ocpi/core/schemas.py
Line 18 in 50b2a07
Due to this hardcoded value, the timestamps always correspondes to the time the app started.
Instead, fix the last line as follows:
from datetime import datetime, timezone
from typing import List, Union
from pydantic import BaseModel, Field
from py_ocpi.core.data_types import String, DateTime, URL
from py_ocpi.core.enums import ModuleID
class OCPIResponse(BaseModel):
"""
https://github.com/ocpi/ocpi/blob/2.2.1/transport_and_format.asciidoc#117-response-format
"""
data: Union[list, dict]
status_code: int
status_message: String(255) # type: ignore
timestamp: DateTime = Field(default_factory=lambda: datetime.now(tz=timezone.utc).isoformat())
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.