Skip to content
This repository has been archived by the owner on Jul 17, 2021. It is now read-only.
/ stib-stub Public archive

Stub server for the STIB-MIVB open data API

License

Notifications You must be signed in to change notification settings

cebamps/stib-stub

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

STIB stub

This small Flask server stubs the STIB-MIVB API.

Endpoints

Supported:

  • /token: stubs the OAuth2 Client Credentials token endpoint, returns a Bearer token. Not secure! (see below)
  • /OperationMonitoring/1.0/VehiclePositionByLine/<ids> (incomplete): returns a JSON file containing only pointId values for the first id requested in the comma-separated list. The other keys are not returned. The pointId values change over time at a regular interval.

Not supported:

  • /OperationMonitoring/1.0/PassingTimeByPoint/<ids>
  • /Files/2.0/Gtfs
  • /Files/2.0/Shapefiles

OAuth2 compliance

Authentication

This stub completely disregards authentication:

  • The token endpoint ignores the provided client credentials and always outputs the same token.
  • The other API endpoints ignore the presence and validity of the attached tokens.

Security

This stub server is not protected by TLS. This can be a problem with compliant OAuth2 client implementations, as the standard states that client credentials and access tokens must not be transmitted in the clear.

With oauthlib, setting the environment variable OAUTHLIB_INSECURE_TRANSPORT to 1 relaxes this security requirement.

About

Stub server for the STIB-MIVB open data API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages