Removes disabling insecure protocols
This is no longer supported on newer Jenkins versions Closes #1093
This commit is contained in:
		
							parent
							
								
									ae9cb0c7f5
								
							
						
					
					
						commit
						83c800789b
					
				|  | @ -72,13 +72,6 @@ def jenkins = Jenkins.instance | ||||||
| 
 | 
 | ||||||
| println("Disabling insecure Jenkins features...") | println("Disabling insecure Jenkins features...") | ||||||
| 
 | 
 | ||||||
| println("Disabling insecure protocols...") |  | ||||||
| println("Old protocols: [" + jenkins.getAgentProtocols().join(", ") + "]") |  | ||||||
| HashSet<String> newProtocols = new HashSet<>(jenkins.getAgentProtocols()) |  | ||||||
| newProtocols.removeAll(Arrays.asList("JNLP3-connect", "JNLP2-connect", "JNLP-connect", "CLI-connect")) |  | ||||||
| println("New protocols: [" + newProtocols.join(", ") + "]") |  | ||||||
| jenkins.setAgentProtocols(newProtocols) |  | ||||||
| 
 |  | ||||||
| println("Disabling CLI access of /cli URL...") | println("Disabling CLI access of /cli URL...") | ||||||
| def remove = { list -> | def remove = { list -> | ||||||
|     list.each { item -> |     list.each { item -> | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue