Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(285)

Side by Side Diff: net/cert/sth_distributor.cc

Issue 1853753003: Certificate Transparency: New component for obtaining fresh STHs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments by sorin & waffles Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "net/cert/sth_distributor.h"
6
7 #include "net/cert/signed_tree_head.h"
8
9 namespace net {
10
11 namespace ct {
12
13 STHDistributor::STHDistributor()
14 : observer_list_(base::ObserverList<STHObserver>::NOTIFY_EXISTING_ONLY) {}
15
16 STHDistributor::~STHDistributor() {}
17
18 void STHDistributor::NewSTHObserved(const SignedTreeHead& sth) {
19 FOR_EACH_OBSERVER(STHObserver, observer_list_, NewSTHObserved(sth));
20 }
21
22 void STHDistributor::RegisterObserver(STHObserver* observer) {
23 observer_list_.AddObserver(observer);
24 }
25
26 void STHDistributor::UnregisterObserver(STHObserver* observer) {
27 observer_list_.RemoveObserver(observer);
28 }
29
30 } // namespace ct
31
32 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698