Skip to content

Improve warning message for Rejected authentication attempts #68671

@ptitdoc

Description

@ptitdoc

I receive a lot of warning messages when a minion is outdated (1 every minute):

salt-master[579023]: [WARNING ] Rejected authentication attempt using protocol version 2 (minimum required: 3)

It makes sense as the minion is really outdated, however, it would be nice to improve the message to see which minion is affected.

I suggest modifying channel/server.py (handle_message()) in order to print out the minion id:

        minimum_version = self.opts.get("minimum_auth_version", 0)
        if minimum_version > 0 and version < minimum_version:
            log.warning(
                "Rejected authentication attempt from minion %s using protocol version %d "
                "(minimum required: %d)",
                payload["load"].get("id","unknown minion"),
                version,
                minimum_version,
            )
            raise tornado.gen.Return("bad load")
[WARNING ] Rejected authentication attempt from osint.xxx.local using protocol version 2 (minimum required: 3)

Now I understand better whats going on.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions