summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/tests/Security/SecurityLevel1/SLevel1_Test_i.h
blob: f1716a12bf7918bac22709e78d0be95596acacb4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// -*- C++ -*-

//=============================================================================
/**
 * @file SLevel1_Test_i.h
 *
 * $Id$
 *
 * Implementation header for the Security Level1test.
 *
 * @author Priyanka Gontla <pgontla@doc.ece.uci.edu>
 */
//=============================================================================

#ifndef TAO_SLEVEL1_TEST_I_H
#define TAO_SLEVEL1_TEST_I_H

#include "SLevel1_TestS.h"
#include "orbsvcs/SecurityLevel1C.h"
#include "openssl/x509.h"

class SLevel1_Server_i : public POA_SLevel1_Server
{
 public:
  /// Constructor
  SLevel1_Server_i (CORBA::ORB_ptr,
                    SecurityLevel1::Current_ptr ss_current);

  /// Simple method invoked to test if the client reached server etc.
  CORBA::Boolean authorize_level1 (CORBA::Environment &)
    ACE_THROW_SPEC ((CORBA::SystemException));

  void shutdown (CORBA::Environment &ACE_TRY_ENV =
                 TAO_default_environment ())
    ACE_THROW_SPEC ((CORBA::SystemException));

  X509 *create_check_cert ();

  static int authorized_1;

 private:

  /// Reference to the ORB.
  CORBA::ORB_var orb_;

  /// Reference to the "SecurityCurrent" object.
  SecurityLevel1::Current_var ss_current_;

};

#endif /* TAO_SLEVEL1_TEST_I_H */