1 Assignment You are hired by a car repair company, CarFIx, that wants to expand and diversify its portfolio by providing car-sharing services. The company has repair shops in multiple cities in Czechia and Slovakia. Their vision is to have a fleet of cars available in the city and their repair shop available for both long-term and short-term rent. Additionally, they require the rent to be in a paperless fashion, promoting a streamlined pay-and-ride model. If the service is successful, the company wants to expand their business beyond the presence of a nearby repair shop. 図 1: Illustration of a sci-fi car 1.1 Renting a Car To rent a car, the customer must order the rental using an app (on the web or mobile). The rental process includes specifying the desired car type or concrete vehicle, selecting the rental duration, pickup and dropoff locations, and itinerary (drivers and states that the car will go through). After selecting a concrete vehicle for rent, the customer can specify additional services (insurance, custom pickup or dropoff point). The price is calculated based on rental duration (price-per-day is cheaper if rented on more days), additional services and insurance (there are multiple insurance tiers). Then, the renter and all drivers sign the contract, and the amount is blocked on the renter’s payment card (Visa, Mastercard). Long-term rental and custom pickups outside the city area need to be approved by a manager. The rented vehicle is available for pickup starting at the specified time and is rented until it is explicitly returned. As the car is keyless, the returning, locking and unlocking are done using the mobile phone (call on a given number) or an app. For optimal user experience, the commands need to be processed in no more than 5 seconds. Locking and unlocking are available to every driver. To start a car, the driver must authorise themselves to the car using asymmetric cryptography. That means that the driver’s public keys are stored on the vehicle and their private key on the user’s device. To return the car, the car must be stationary, empty, locked, and full fuel tank/battery. 1.2 Fees Additional fees might apply. If the car is not returned in the given time (plus a one-hour buffer), the renter is billed in a pay-as-you-drive manner, plus an additional 50% charge. If the renter returns the car to a different location (300 m radius), they pay an additional fee. It is based on the distance (the fee is tiered, so leaving the car in the same city is less expensive than leaving it in a different city). Furthermore, the renter might request changes to their rental. This includes adding additional drivers or changing the itinerary. These are billed as normal. However, additional charges might apply if there is an 1 unauthorised action (going abroad). Change needs to be approved by a manager. Extending the rental is only possible if there is no pending reservation on the same vehicle. Additionally, the rental can be cancelled or returned prematurely with 75% cancellation fee. 1.3 User Account In order to use the service, the user must be registered. The registration contains all the necessary information for billing purposes. Additionally, to drive a car, the user needs to insert their driver’s licence information and generate a key for the car authorisation. The customer can delete their account anytime; however, the history is retained. To comply with privacy regulations, rentals older than two years without an active account can retain only the rental contract. 1.4 Vehicle Fleet CarFIx company owns a fleet of vehicles for rental. Each vehicle is organised under one shop, based on proximity. The cars might be transferred at will by an operator. Each car falls under a category (e.g., sport, small, XL, pickup, electric, automatic, luxury) to ease searching. Additionally, each car has a different price tier for rental. Some cars are also available for pay-as-you-go service. Each car has its onboard infotainment system and set of sensors (location, speed, fuel). It has a “CarBoardX” API that supports driver’s accounts and uses a cryptographically secure, authenticated channel. The telemetry is transmitted periodically using the MQTT protocol. If the car is running out of fuel/charge, it is unavailable for pay-as-you-go and notifies the operator. A technician then picks up the car using a service key/token. 1.5 Pay-as-you-Drive Some vehicles are available in pay-as-you-drive rental. Anybody can see the available vehicles. To rent the vehicle, only the start time is reserved with an unspecified end time. The vehicle might then be driven only by the renter and might be returned only to a designated area (typically a city). It might be driven outside the city limits but must not cross the state border. The customer is billed depending on the rented time. A special discount is provided if the car is dropped at a specified location (specific parking space or charging stand). 1.6 Promotions By using the service, the user receives points to a “genius” program. It is a tiered bonus programme offering discounts. The points towards this programme are gained by driving the car and paying for the reservation. During the rental, the user has a discount in affiliated shops (e.g. fuel stations, parking lots, roadhouses). 2