1. 06 2月, 2021 1 次提交
  2. 05 2月, 2021 3 次提交
  3. 04 2月, 2021 1 次提交
  4. 03 2月, 2021 3 次提交
  5. 02 2月, 2021 1 次提交
  6. 31 1月, 2021 2 次提交
  7. 29 1月, 2021 1 次提交
  8. 27 1月, 2021 3 次提交
    • Zach Wasserman's avatar
      Update documentation about denylist schedule key (#6922) · 3d2d2ba0
      Zach Wasserman 创作于
      Attempts to clear up a common misconception about the functionality of
      the `denylist` key.
      3d2d2ba0
    • Stefano Bonicatti's avatar
      Rename yara str functions to avoid symbol collisions (#6917) · 776eba97
      Stefano Bonicatti 创作于
      Yara publicly exposes the definition of various str functions like
      strlcpy, strlcat and so on if they are not present on the system
      it is compiled on.
      
      This is not ideal because other libraries use custom implementations
      of those functions and those symbols would collide with
      the public ones from yara, therefore we rename them
      to avoid the collision.
      776eba97
    • Stefano Bonicatti's avatar
      Significantly speed up CMake configuration phase (#6914) · 6893a72e
      Stefano Bonicatti 创作于
      This speeds up the configuration phase and simplifies having
      control of the compilation flags used.
      
      Additional changes were required due to other libraries incorrectly
      depending on glog and gflags cmake code or headers.
      smartmontools especially, was incorrectly publicly depending
      on its own config.h, which was though taken from glog
      when smartmontools libsmartclt.h header was included by user code.
      A fix has been done on the smartmontools side and so the submodule
      commit we refer to has been updated.
      6893a72e
  9. 26 1月, 2021 1 次提交
  10. 25 1月, 2021 1 次提交
  11. 22 1月, 2021 1 次提交
  12. 21 1月, 2021 1 次提交
  13. 20 1月, 2021 1 次提交
  14. 18 1月, 2021 3 次提交
  15. 16 1月, 2021 3 次提交
  16. 15 1月, 2021 2 次提交
  17. 14 1月, 2021 1 次提交
  18. 13 1月, 2021 1 次提交
  19. 11 1月, 2021 4 次提交
  20. 10 1月, 2021 2 次提交
    • Stefano Bonicatti's avatar
      Fix a leak in libdpkg when querying the deb_packages table (#6892) · 8cc6d99c
      Stefano Bonicatti 创作于
      libdpkg is leaking memory on every initialization.
      Initialization happens everytime deb_packages gets queried.
      
      The memory leaked is allocated for the "triggersdir"
      global variable by "dpkg_db_get_path" called in "trigdef_update_start".
      "trigdef_update_start" is called by "trig_incorporate" just after
      the memory for "triggersdir" has been allocated.
      In some occasions "trigdef_update_start" is also called two times in a
      row. In all these cases the memory do not get deallocated in between calls,
      so the old memory is lost.
      
      Since the result of "dpkg_db_get_path" depends on the database dir that
      has been set, and in the "trigdef_update_start" function it's not possible
      to know if it has changed from the previous allocation or not,
      it's necessary to always deallocate vs just avoid to call "dpkg_db_get_path".
      
      Fix also a couple of other leaks on error.
      8cc6d99c
    • Brendan Shaklovitz's avatar
      0ff6e704
  21. 04 1月, 2021 1 次提交
  22. 03 1月, 2021 1 次提交
    • Stefano Bonicatti's avatar
      Fix UB and dangerous casting in the pubsub framework (#6881) · 3b06d321
      Stefano Bonicatti 创作于
      - Downcasting a shared_ptr to a type T2 that's not a derived class or a base class of T1,
        even if they share the same base class B, it's undefined behaviour.
        For instance BPFEventPublisher inherits from EventPublisher<BPFEventSC,BPFEventEC>,
        which is a template that inherits from EventPublisherPlugin, which
        further inherits from Plugin.
        The register function was called passing an instance of std::shared_ptr<BPFEventPublisher>
        which was implicitly upcasted to std::shared_ptr<Plugin> as the
        function parameter.
        Then such parameter was downcasted to std::shared_ptr<EventPublisherPlugin>
        (which was fine), then further downcasted to std::shared_ptr<BaseEventPlugin>
        which actually was std::shared_ptr<EventPublisher<SubscriptionContext, EventContext>>.
        Although the two EventPublisher template parameters are base classes
        of BPFEventSC and BPFEventEC, the resulting concrete EventPublisher
        class is not related to BPFEventPublisher, so this is UB.
        This was done in an attempt to have a common type for all publishers
        to be used to store them into a std::map. Instead of using such type,
        use EventPublisherPlugin.
        A very similar thing happens with subcribers.
      
      - Fix an incorrect success when a std::shared_ptr<Plugin>
        fails to be downcasted to a std::shared_ptr<EventPublisherPlugin>,
        in EventFactory::registerEventPublisher.
      
      - Substitute dangerous reinterpret_cast on a pointer to a member function
        callback in EventSubscriber<PUB>::subscribe with a safer approach
        which uses a lambda that captures the object it has to call the callback on
        and properly converts the arguments, downcasting them to the appropriate type.
        Also remove a redundant template parameter.
      
      - Add a virtual destructor to SubscriptionContext and EventContext
        structs since they are inherited from
        and used in a polymorphic context as pointers.
      3b06d321
  23. 02 1月, 2021 2 次提交