View | Details | Raw Unified | Return to bug 3153 | Differences between
and this patch

Collapse All | Expand All

(-)a/sshconnect2.c (-7 / +10 lines)
Lines 1549-1559 key_type_allowed_by_config(struct sshkey *key) Link Here
1549
1549
1550
/*
1550
/*
1551
 * try keys in the following order:
1551
 * try keys in the following order:
1552
 * 	1. certificates listed in the config file
1552
 *	1. keys directly provided by the user
1553
 * 	2. other input certificates
1553
 *	2. certificates listed in the config file
1554
 *	3. agent keys that are found in the config file
1554
 *	3. other input certificates
1555
 *	4. other agent keys
1555
 *	4. agent keys that are found in the config file
1556
 *	5. keys that are only listed in the config file
1556
 *	5. other agent keys
1557
 *	6. keys that are only listed in the config file
1557
 */
1558
 */
1558
static void
1559
static void
1559
pubkey_prepare(Authctxt *authctxt)
1560
pubkey_prepare(Authctxt *authctxt)
Lines 1689-1695 pubkey_prepare(Authctxt *authctxt) Link Here
1689
	/* append remaining keys from the config file */
1690
	/* append remaining keys from the config file */
1690
	for (id = TAILQ_FIRST(&files); id; id = TAILQ_FIRST(&files)) {
1691
	for (id = TAILQ_FIRST(&files); id; id = TAILQ_FIRST(&files)) {
1691
		TAILQ_REMOVE(&files, id, next);
1692
		TAILQ_REMOVE(&files, id, next);
1692
		TAILQ_INSERT_TAIL(preferred, id, next);
1693
		if (id->userprovided)
1694
			TAILQ_INSERT_HEAD(preferred, id, next);
1695
		else
1696
			TAILQ_INSERT_TAIL(preferred, id, next);
1693
	}
1697
	}
1694
	/* finally, filter by PubkeyAcceptedKeyTypes */
1698
	/* finally, filter by PubkeyAcceptedKeyTypes */
1695
	TAILQ_FOREACH_SAFE(id, preferred, next, id2) {
1699
	TAILQ_FOREACH_SAFE(id, preferred, next, id2) {
1696
- 

Return to bug 3153