This file is indexed.

/usr/include/shibsp/SPConfig.h is in libshibsp-dev 2.5.3+dfsg-2+deb8u1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
/**
 * Licensed to the University Corporation for Advanced Internet
 * Development, Inc. (UCAID) under one or more contributor license
 * agreements. See the NOTICE file distributed with this work for
 * additional information regarding copyright ownership.
 *
 * UCAID licenses this file to you under the Apache License,
 * Version 2.0 (the "License"); you may not use this file except
 * in compliance with the License. You may obtain a copy of the
 * License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
 * either express or implied. See the License for the specific
 * language governing permissions and limitations under the License.
 */

/**
 * @file shibsp/SPConfig.h
 *
 * Library configuration.
 */

#ifndef __shibsp_config_h__
#define __shibsp_config_h__

#include <shibsp/base.h>

#include <string>
#ifndef SHIBSP_LITE
# include <shibsp/TransactionLog.h>
# include <saml/binding/MessageDecoder.h>
# include <saml/binding/MessageEncoder.h>
#endif
#include <xmltooling/PluginManager.h>
#include <xmltooling/QName.h>
#include <xercesc/dom/DOM.hpp>

/**
 * @namespace shibsp
 * Shibboleth Service Provider Library
 */
namespace shibsp {

    class SHIBSP_API AccessControl;
    class SHIBSP_API Handler;
    class SHIBSP_API ListenerService;
    class SHIBSP_API RequestMapper;
    class SHIBSP_API ProtocolProvider;
    class SHIBSP_API ServiceProvider;
    class SHIBSP_API SessionCache;
    class SHIBSP_API SessionInitiator;

#ifndef SHIBSP_LITE
    class SHIBSP_API AttributeDecoder;
    class SHIBSP_API AttributeExtractor;
    class SHIBSP_API AttributeFilter;
    class SHIBSP_API AttributeResolver;
    class SHIBSP_API FilterPolicyContext;
    class SHIBSP_API MatchFunctor;
    class SHIBSP_API SecurityPolicyProvider;
#endif

#if defined (_MSC_VER)
    #pragma warning( push )
    #pragma warning( disable : 4250 4251 )
#endif

    /**
     * Singleton object that manages library startup/shutdown.
     */
    class SHIBSP_API SPConfig
    {
        MAKE_NONCOPYABLE(SPConfig);
    public:
        SPConfig();

        virtual ~SPConfig();

        /**
         * Returns the global configuration object for the library.
         *
         * @return reference to the global library configuration object
         */
        static SPConfig& getConfig();

        /**
         * Bitmask values representing subsystems of the library.
         */
        enum components_t {
            Listener = 1,
            Caching = 2,
#ifndef SHIBSP_LITE
            Metadata = 4,
            Trust = 8,
            Credentials = 16,
            AttributeResolution = 32,
#endif
            RequestMapping = 64,
            OutOfProcess = 128,
            InProcess = 256,
            Logging = 512,
            Handlers = 1024
        };

        /**
         * Set a bitmask of subsystems to activate.
         *
         * @param enabled   bitmask of component constants
         */
        void setFeatures(unsigned long enabled);


        /**
         * Gets the bitmask of subsystems being activated.
         *
         * @return bitmask of component constants
         */
        unsigned long getFeatures() const;

        /**
         * Test whether a subsystem is enabled.
         *
         * @param feature   subsystem/component to test
         * @return true iff feature is enabled
         */
        bool isEnabled(components_t feature) const;

        /**
         * Initializes library
         *
         * Each process using the library MUST call this function exactly once
         * before using any library classes.
         *
         * @param catalog_path  delimited set of schema catalog files to load
         * @param inst_prefix   installation prefix for software
         * @return true iff initialization was successful
         */
        virtual bool init(const char* catalog_path=nullptr, const char* inst_prefix=nullptr);

        /**
         * Shuts down library
         *
         * Each process using the library SHOULD call this function exactly once
         * before terminating itself.
         */
        virtual void term();

        /**
         * Sets the global ServiceProvider instance.
         * This method must be externally synchronized with any code that uses the object.
         * Any previously set object is destroyed.
         *
         * @param serviceProvider   new ServiceProvider instance to store
         */
        void setServiceProvider(ServiceProvider* serviceProvider);

        /**
         * Returns the global ServiceProvider instance.
         *
         * @return  global ServiceProvider or nullptr
         */
        ServiceProvider* getServiceProvider() const;

        /**
         * Instantiates and installs a ServiceProvider instance based on an XML configuration string
         * or a configuration pathname.
         *
         * @param config    a snippet of XML to parse (it <strong>MUST</strong> contain a type attribute) or a pathname
         * @param rethrow   true iff caught exceptions should be rethrown instead of just returning the status
         * @return true iff instantiation was successful
         */
        virtual bool instantiate(const char* config=nullptr, bool rethrow=false);

#ifndef SHIBSP_LITE
        /**
         * Sets the global ArtifactResolver instance.
         *
         * <p>This method must be externally synchronized with any code that uses the object.
         * Any previously set object is destroyed.
         *
         * @param artifactResolver   new ArtifactResolver instance to store
         */
        void setArtifactResolver(opensaml::MessageDecoder::ArtifactResolver* artifactResolver);

        /**
         * Returns the global ArtifactResolver instance.
         *
         * @return  global ArtifactResolver or nullptr
         */
        const opensaml::MessageDecoder::ArtifactResolver* getArtifactResolver() const;
#endif

        /** Separator for serialized values of multi-valued attributes. */
        char attribute_value_delimeter;

        /**
         * Manages factories for AccessControl plugins.
         */
        xmltooling::PluginManager<AccessControl,std::string,const xercesc::DOMElement*> AccessControlManager;

#ifndef SHIBSP_LITE
        /**
         * Manages factories for AttributeDecoder plugins.
         */
        xmltooling::PluginManager<AttributeDecoder,xmltooling::QName,const xercesc::DOMElement*> AttributeDecoderManager;

        /**
         * Manages factories for AttributeExtractor plugins.
         */
        xmltooling::PluginManager<AttributeExtractor,std::string,const xercesc::DOMElement*> AttributeExtractorManager;

        /**
         * Manages factories for AttributeFilter plugins.
         */
        xmltooling::PluginManager<AttributeFilter,std::string,const xercesc::DOMElement*> AttributeFilterManager;

        /**
         * Manages factories for AttributeResolver plugins.
         */
        xmltooling::PluginManager<AttributeResolver,std::string,const xercesc::DOMElement*> AttributeResolverManager;

        /**
         * Manages factories for Event plugins.
         */
        xmltooling::PluginManager<TransactionLog::Event,std::string,void*> EventManager;

        /**
         * Manages factories for MatchFunctor plugins.
         */
        xmltooling::PluginManager< MatchFunctor,xmltooling::QName,std::pair<const FilterPolicyContext*,const xercesc::DOMElement*> > MatchFunctorManager;

        /**
         * Manages factories for SecurityPolicyProvider plugins.
         */
        xmltooling::PluginManager<SecurityPolicyProvider,std::string,const xercesc::DOMElement*> SecurityPolicyProviderManager;
#endif

        /**
         * Manages factories for Handler plugins that implement ArtifactResolutionService functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > ArtifactResolutionServiceManager;

        /**
         * Manages factories for Handler plugins that implement AssertionConsumerService functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > AssertionConsumerServiceManager;

        /**
         * Manages factories for Handler plugins that implement customized functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > HandlerManager;

        /**
         * Manages factories for ListenerService plugins.
         */
        xmltooling::PluginManager<ListenerService,std::string,const xercesc::DOMElement*> ListenerServiceManager;

        /**
         * Manages factories for Handler plugins that implement LogoutInitiator functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > LogoutInitiatorManager;

        /**
         * Manages factories for Handler plugins that implement ManageNameIDService functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > ManageNameIDServiceManager;

        /**
         * Manages factories for ProtocolProvider plugins.
         */
        xmltooling::PluginManager<ProtocolProvider,std::string,const xercesc::DOMElement*> ProtocolProviderManager;

        /**
         * Manages factories for RequestMapper plugins.
         */
        xmltooling::PluginManager<RequestMapper,std::string,const xercesc::DOMElement*> RequestMapperManager;

        /**
         * Manages factories for ServiceProvider plugins.
         */
        xmltooling::PluginManager<ServiceProvider,std::string,const xercesc::DOMElement*> ServiceProviderManager;

        /**
         * Manages factories for SessionCache plugins.
         */
        xmltooling::PluginManager<SessionCache,std::string,const xercesc::DOMElement*> SessionCacheManager;

        /**
         * Manages factories for Handler plugins that implement SessionInitiator functionality.
         */
        xmltooling::PluginManager< SessionInitiator,std::string,std::pair<const xercesc::DOMElement*,const char*> > SessionInitiatorManager;

        /**
         * Manages factories for Handler plugins that implement SingleLogoutService functionality.
         */
        xmltooling::PluginManager< Handler,std::string,std::pair<const xercesc::DOMElement*,const char*> > SingleLogoutServiceManager;

    protected:
        /** Global ServiceProvider instance. */
        ServiceProvider* m_serviceProvider;

#ifndef SHIBSP_LITE
        /** Global ArtifactResolver instance. */
        opensaml::MessageDecoder::ArtifactResolver* m_artifactResolver;
#endif

    private:
        unsigned long m_features;
        xercesc::DOMDocument* m_configDoc;
    };

#if defined (_MSC_VER)
    #pragma warning( pop )
#endif

};

#endif /* __shibsp_config_h__ */