Getting Started

Connect Fastly

Configure a Fastly HTTPS logging endpoint and attach the Honeylog response condition.

Use this guide when Fastly handles visits to the website. You will add a Honeylog logging destination to a draft Fastly service version and activate it after checking the settings.

#Before you open Fastly

Sign in to the Fastly account that manages this website. Your account must be allowed to clone, edit, and activate its service configuration. If not, send this guide and the private Honeylog installation page to your Fastly administrator.

#Step 1: Clone the active Fastly version

  1. Open the Fastly service that handles this website.
  2. Open the active version and clone it so the changes are made on a draft version.
  3. Stay on the cloned version for the next steps.

Before continuing, confirm that Fastly shows the cloned version as editable and that the currently active version has not changed.

Fastly service configuration page with Clone to edit highlighted
Clone the locked active version so the Honeylog changes are made on an editable draft.

#Step 2: Create the HTTPS logging endpoint

  1. In the cloned version, open Logging.
Fastly Logging page with the Honeylog HTTPS endpoint
Open Logging inside the cloned Fastly service version.
  1. Click Add endpoint, then choose HTTPS.
Fastly Add endpoint menu with HTTPS selected
Choose HTTPS from the Add endpoint menu.
  1. Paste the generated Honeylog values into the matching endpoint fields.

Endpoint values:

Name: honeylog
Placement: Format Version Default
URL: https://api.honeylog.io/fastly/events/SITE_DOMAIN
Method: POST
Content type: application/json
Log line format: JSON array
Maximum logs: 100
Maximum bytes: 500000
Compression: None
Custom header name: Authorization
Custom header value: Bearer SITE_TOKEN

Use the personalized URL and secret from Settings > Installation > Fastly in Honeylog. Do not use SITE_DOMAIN or SITE_TOKEN literally.

Before continuing, confirm that the endpoint is named honeylog and that every field matches the list above.

#Step 3: Paste the log format

Paste the Honeylog log format into the Log format field of the HTTPS endpoint.

Open log-format.txt

Save the endpoint and confirm that Fastly still shows the complete log format in the field.

#Step 4: Add the response condition

  1. On the honeylog HTTPS logging endpoint, click Attach condition.
Fastly Honeylog HTTPS endpoint with Attach condition highlighted
Attach a response condition to the Honeylog HTTPS logging endpoint.
  1. Keep the condition type set to Response.
  2. Name the condition Honeylog conditions.
  3. Paste the condition generated by Honeylog into the Apply if field. This rule tells Fastly which website requests should be sent to Honeylog.
  4. Click Attach.
Fastly response condition modal with the Honeylog Apply if expression
Paste the Honeylog response condition into Apply if, then attach it.

Open response-condition.txt

Before continuing, confirm that Honeylog conditions appears as the response condition attached to the honeylog endpoint.

#Step 5: Activate and verify

  1. Review the cloned version and activate it.
  2. Wait until Fastly shows that this version is active.
  3. Open a few public pages on the website.
  4. Wait a few minutes, then open Honeylog and confirm that the new visits appear.

Fastly may need a few minutes to start sending logs after activation. If no visits appear, open more than one public page and wait a few more minutes before troubleshooting.