public Handshake(String s) throws MalformedHeaderException {
		//System.out.println(s);
		String[] headers_received = s.split("\n");
		
		for (String header : headers_received) {
			Header h = null;
			try {
				h = new Header(header);
			} catch (SpecialHeaderException ex) {
				Class search = ex.getCorrectType();
				if (search.equals(LocationHeader.class)) {
					h = new LocationHeader(header);
				}
				else if (search.equals(SecureWebSocketKeyHeader.class)) {
					h = new SecureWebSocketKeyHeader(header);
				}
			}
			
			if (h != null) {
				this.headers.put(h.getKey(), h);
			}
		}
	}