aboutsummaryrefslogtreecommitdiff
path: root/third_party/libuweave/src/macaroon_context.c
blob: 747778477b868b13e47d9383ca4f819560608e9a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Copyright 2015 The Weave Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "src/macaroon_context.h"

#include "src/macaroon_caveat.h"

bool uw_macaroon_context_get_(UwMacaroonCaveatType type,
                              const uint8_t** context, size_t* context_len) {
  if (type != kUwMacaroonCaveatTypeSessionIdentifier) {
    *context = NULL;
    *context_len = 0;
  }

  // TODO(bozhu): Waiting for a proper way to obtain the session identifier.
  // Have we already implemented something related to session identifiers?
  *context = NULL;
  *context_len = 0;

  return true;
}