public void setChaddr(byte[] chaddr) {
        if (chaddr != null) {
            if (chaddr.length > this.chaddr.length) {
                throw new IllegalArgumentException("chaddr is too long: " + chaddr.length +
                                                   ", max is: " + this.chaddr.length);
            }
            Arrays.fill(this.chaddr, (byte) 0);
            System.arraycopy(chaddr, 0, this.chaddr, 0, chaddr.length);
        } else {
            Arrays.fill(this.chaddr, (byte) 0);
        }
    }