blob: 512b32fff998cd2d451fa07700e5c57e15660053 [file] [log] [blame]
// Copyright 2022 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef VTPM_COMMANDS_NULL_COMMAND_H_
#define VTPM_COMMANDS_NULL_COMMAND_H_
#include "vtpm/commands/command.h"
#include <string>
#include <base/callback.h>
namespace vtpm {
// A null implementation of `Command`. it does nothing but always use an empty
// string as the TPM response.
// Used for testing purpose as a placeholder.
class NullCommand : public Command {
public:
// Calls `callback` with empty TPM response, no matter what is in `command`.
void Run(const std::string& command,
CommandResponseCallback callback) override;
};
} // namespace vtpm
#endif // VTPM_COMMANDS_NULL_COMMAND_H_