Skip to content

certificate_check callback not used in remote.connect or remote.ls_remotes #1262

Closed
@kevinvalk

Description

@kevinvalk

As far as I can see the remote_callbacks struct is not properly initialized with the certificate_check callback (https://libgit2.org/libgit2/#v0.23.2/type/git_remote_callbacks).

pygit2/pygit2/callbacks.py

Lines 384 to 387 in 611a3b3

# Plug callbacks
cdata.credentials = C._credentials_cb
cdata.update_tips = C._update_tips_cb
# Payload

This makes it impossible to "bypass" certificate checks for example when testing remotes. So I think simply adding to the callback options is enough, but do not quote me on that!

cdata.certificate_check = C._certificate_cb

This also may be the problem for #945

P.S. Its point about certificate_check vs certificate still stands so that could also be sorted out.

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