General Information

The repository for this application (open on GitHub) has 655 stars and was forked 1037 times. The codebase consists of 638 lines of code and makes use of the following technologies:

Eureka Maven

Data Flow Diagram

Dataflow Diagram

Download the following model file here. Other formats are provided below.

{
    "services": [
        {
            "name": "discovery_server",
            "stereotypes": [
                "infrastructural",
                "service_discovery"
            ],
            "tagged_values": {
                "Port": 8761,
                "Service Discovery": "Eureka"
            }
        },
        {
            "name": "ratings_data_service",
            "stereotypes": [
                "internal"
            ],
            "tagged_values": {
                "Port": 8083,
                "Endpoints": [
                    "/ratingsdata",
                    "/ratingsdata/movies/{movieId}",
                    "/ratingsdata/user/{userId}"
                ]
            }
        },
        {
            "name": "movie_info_service",
            "stereotypes": [
                "internal"
            ],
            "tagged_values": {
                "Port": 8082,
                "Endpoints": [
                    "/movies",
                    "/movies/{movieId}"
                ]
            }
        },
        {
            "name": "movie_catalog_service",
            "stereotypes": [
                "internal",
                "load_balancer"
            ],
            "tagged_values": {
                "Port": 8081,
                "Load Balancer": "Spring Cloud",
                "Endpoints": [
                    "/catalog",
                    "/catalog/{userId}"
                ]
            }
        }
    ],
    "information_flows": [
        {
            "sender": "ratings_data_service",
            "receiver": "discovery_server",
            "stereotypes": [
                "restful_http"
            ],
            "tagged_values": {}
        },
        {
            "sender": "movie_info_service",
            "receiver": "discovery_server",
            "stereotypes": [
                "restful_http"
            ],
            "tagged_values": {}
        },
        {
            "sender": "external_website",
            "receiver": "movie_info_service",
            "stereotypes": [
                "restful_http"
            ],
            "tagged_values": {}
        },
        {
            "sender": "movie_catalog_service",
            "receiver": "discovery_server",
            "stereotypes": [
                "restful_http",
                "load_balanced_link"
            ],
            "tagged_values": {}
        },
        {
            "sender": "movie_catalog_service",
            "receiver": "ratings_data_service",
            "stereotypes": [
                "restful_http",
                "load_balanced_link"
            ],
            "tagged_values": {}
        },
        {
            "sender": "movie_catalog_service",
            "receiver": "movie_info_service",
            "stereotypes": [
                "restful_http",
                "load_balanced_link"
            ],
            "tagged_values": {}
        }
    ],
    "external_entities": [
        {
            "name": "external_website",
            "stereotypes": [
                "external_website"
            ],
            "tagged_values": {
                "URL": "https://api.themoviedb.org"
            }
        }
    ]
}

Model Items

The Application consists of a total of 37 elements:

Element Count
Services 4
External Entities 1
Information Flows 6
Annotations 26
Total Items 37

Model Representations

Open the model in the following formats:

Traceability

Open the traceability information for all model items:

Security Rules

The following table shows the application’s adherence to the 17 architectural security rules. The last column provides model variants that adhere to the rule for each rule that is initially violated.

Rule ID    Verdict       Evidence        Model Variant    
R1 Evidence Variant
R2 Evidence Variant
R3 Evidence Variant
R4 Evidence Variant
R5 Evidence Variant
R6 Evidence Variant
R7 Evidence Variant
R8 Evidence Variant
R9 Evidence Variant
R10 Evidence Variant
R11 Evidence Variant
R12 Evidence Variant
R13 Evidence Variant
R14 Evidence Variant
R16 Evidence  
R17 Evidence Variant
R18 Evidence Variant

Evidence and explanations for rule decisions

R1

Rule is violated: All three services marked as internal can be accessed independently.

Artifacts:

  • MovieCatalogServiceApplication.java: Line: 10
  • MovieInfoServiceApplication.java: Line: 9
  • RatingsDataServiceApplication.java: Line: 7

R2

Rule is violated: Unauthenticated requests are sent from the catalog service to other services.

Artifacts:

  • CatalogResource.java: Line: 36
  • CatalogResource.java: Line: 32

R3

Rule is violated: No authentication mechanism is deployed.

R4

Rule is violated: External entities are not represented in the application.

R5

Rule is violated: No authentication tokens are used.

R6

Rule is violated: No rate limiting of any means is deployed.

R7

Rule is violated: User external entities can call the gateway service using an unencrypted HTTP connection.

R8

Rule is violated: All internal services communicate over insecure HTTP connections.

Artifacts:

  • CatalogResource.java: Lines: 32, 36, 46

R9

Rule is violated: No central logging system is deployed.

R10

Rule is violated: No central logging system is deployed.

R11

Rule is violated: Logs are not explicitly sanitized.

R12

Rule is violated: No explicit logging mechanism is deployed.

R13

Rule is violated: No explicit circuit breaker is deployed.

R14

Rule is violated: There exists no API gateway since each service is accessed on a different user-facing port. The movie catalog service performs load balancing, but the ratings and movie info services do not.

Artifacts:

  • MovieCatalogServiceApplication.java: Line: 18

R15

This rule is not applicable: Not a service mesh deployment.

R16

Rule is adhered to:

  1. Registry Service (Eureka Server) with @EnableEurekaServer present.
  2. Project is missing infrastructure description, not certain if and how the discovery server is deployed.

Artifacts:

  • DiscoveryServerApplication.java: Line: 8

R17

Rule is violated: No HTTP basic password listed in any YML-Configuration of format username:password@here-location-of-eureka-server at “eureka.client.serviceUrl.defaultZone”.

Artifacts:

  • DiscoveryServerApplication.java: Line: 8

R18

Rule is violated: No secret manager is deployed. The secret API key used for the external movie database API is stored as a configuration key in the service instance.

Artifacts:

  • application.properties: Line: 4
Tags: eureka maven