Skip to content

[RFC] Is it time to switch 'el-get-allow-insecure to nil#2439

Open
manandbytes wants to merge 1 commit intodimitri:masterfrom
manandbytes:insecure-check
Open

[RFC] Is it time to switch 'el-get-allow-insecure to nil#2439
manandbytes wants to merge 1 commit intodimitri:masterfrom
manandbytes:insecure-check

Conversation

@manandbytes
Copy link
Copy Markdown
Contributor

@manandbytes manandbytes commented Sep 2, 2016

...and cut a new release? Please, do not merge yet as, in the first place, I'm looking for feedback if I'm doing something completely stupid ;-)
I'm going update some commit messages and documentation later.

Unresolved issues

Comment thread el-get-methods.el Outdated
(when (and (not el-get-allow-insecure)
(not (stringp (car (member protocol el-get-secure-protocols))))
(not file-local)
(not (string-match "^[-_\.A-Za-z0-9]+@" url)))
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't remember a signle case of such URL and going to remove support for URLs starting with 'USERNAME@'.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ssh+git URLs can start with USERNAME@, see https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols#The-SSH-Protocol. Apparently ssh://USERNAME@... also works, but github always offers git@github.com... for ssh URLs.

@npostavs
Copy link
Copy Markdown
Collaborator

npostavs commented Sep 2, 2016

...and cut a new release?

We're currently in a "rolling release" model, which simplifies the questions of how to upgrade from an older release to a new one :) So before cutting a release we'd have to think about how to answer those.

Comment thread el-get-custom.el Outdated
(defcustom el-get-secure-protocols '("https" "ssh" "git+ssh" "bzr+ssh" "sftp")
"List of secure protocols"
:group 'el-get
:package-version '(el-get-custom . "6")
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No sure if el-get-custom is the right package as el-get-methods.el actually depends on el-get-secure-protocols. Or even (el-get . "6")?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The package should be just el-get, I think. el-get-custom is not versioned independently.

@npostavs
Copy link
Copy Markdown
Collaborator

npostavs commented Sep 3, 2016

Hmm, perhaps we should tag some kind of release, since it seems that el-get is in melpa-stable right now (see #2438).

@manandbytes manandbytes force-pushed the insecure-check branch 3 times, most recently from 28bae7e to a001240 Compare September 4, 2016 08:54
Comment thread el-get-methods.el Outdated
(defun el-get-insecure-check (package url)
(let* ((checksum (plist-get (el-get-package-def package) :checksum))
(defun el-get-insecure-check (PACKAGE URL)
"Check if it's safe to install PACKAGE from url.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still not sure about the docstring...

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be from URL, and I think the docstring should mention that an error is thrown if it's insecure/not safe. Otherwise looks good to me.

@manandbytes
Copy link
Copy Markdown
Contributor Author

As it turned out this PR's main feature is defcustom for the list of secure URL protocols, I'm not sure what to do next. I'm going to create a separate PR for this, is it 🆗?

These commits are not ready anyway and should not block the rest:

  • [RFC] Time to switch 'el-get-allow-insecure to nil
  • Semantic URL parsing
  • [WIP] Don't consider URL starting with 'username@' as secure

@npostavs
Copy link
Copy Markdown
Collaborator

npostavs commented Sep 4, 2016

I'm going to create a separate PR for this, is it 🆗?

Sure thing.

@manandbytes
Copy link
Copy Markdown
Contributor Author

I'm going to create a separate PR for this, is it 🆗?

Sure thing.

Done, #2441.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants