monotone

monotone Mtn Source Tree

Root/src/ssh_agent.hh

1// Copyright (C) 2007 Justin Patrin <papercrane@reversefold.com>
2//
3// This program is made available under the GNU GPL version 2.0 or
4// greater. See the accompanying file COPYING for details.
5//
6// This program is distributed WITHOUT ANY WARRANTY; without even the
7// implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8// PURPOSE.
9
10#ifndef __SSH_AGENT_H__
11#define __SSH_AGENT_H__
12
13#include "vector.hh"
14#include <boost/scoped_ptr.hpp>
15
16struct keypair;
17
18namespace Botan
19{
20 class RSA_PublicKey;
21 class RSA_PrivateKey;
22};
23
24class ssh_agent_state;
25
26struct ssh_agent
27{
28 ssh_agent();
29 ~ssh_agent();
30 std::vector<Botan::RSA_PublicKey> const get_keys();
31 bool has_key(const keypair & key);
32 void sign_data(Botan::RSA_PublicKey const & key,
33 std::string const & data,
34 std::string & out);
35 void add_identity(Botan::RSA_PrivateKey const & key,
36 std::string const & comment);
37 bool connected();
38
39private:
40 boost::scoped_ptr<ssh_agent_state> s;
41};
42
43#endif
44
45// Local Variables:
46// mode: C++
47// fill-column: 76
48// c-file-style: "gnu"
49// indent-tabs-mode: nil
50// End:
51// vim: et:sw=2:sts=2:ts=2:cino=>2s,{s,\:s,+s,t0,g0,^-2,e-2,n-2,p2s,(0,=s:

Archive Download this file

Branches

Tags

Quick Links:     www.monotone.ca    -     Downloads    -     Documentation    -     Wiki    -     Code Forge    -     Build Status