/*
- * Copyright (c) 2013 - 2019 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2013 - 2020 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
class AccessProvider {
public:
- explicit AccessProvider(const std::string &ownerId);
AccessProvider(const std::string &ownerId, int uid, int gid);
virtual ~AccessProvider();
void allowAPI(const std::string &api, const std::string &rules);
void apply();
void applyAndSwithToUser(int uid, int gid);
+ void clear();
private:
void allowJournaldLogs();
class ScopedAccessProvider : public AccessProvider {
public:
- explicit ScopedAccessProvider(const std::string &mySubject)
- : AccessProvider(mySubject) {}
ScopedAccessProvider(const std::string &mySubject, int uid, int gid)
: AccessProvider(mySubject, uid, gid) {}
virtual ~ScopedAccessProvider();