+ //BRCM_begin
+ vendorid = get_option(&packet, DHCP_VENDOR);
+
+ /* Check the vendor ID with the configured vendor ID */
+ if (read_vendor_id_config(DHCPD_VENDORID_CONF_FILE) == 1) {
+ vendor_id_cfg = 1;
+ }
+ if (vendor_id_cfg) {
+ int i = 0;
+ for (i = 0; i < MAX_VENDOR_IDS; i++) {
+ if (strlen(vendor_id_config[i].vendorid) == 0) {
+ continue;
+ }
+ memset(opt_vend, 0, 64);
+ memcpy(opt_vend, vendorid, strlen(vendor_id_config[i].vendorid) - 1);
+ if (strncmp(opt_vend, vendor_id_config[i].vendorid,
+ strlen(vendor_id_config[i].vendorid) - 1) == 0) {
+ memset(declines, 0, sizeof(struct dhcpOfferedAddr));
+ memcpy(declines->chaddr, packet.chaddr, 16);
+ memcpy(declines->vendorid, vendorid, 64);
+ /* Write this to the decline file */
+ write_decline(0);
+ /* remain silent */
+ sendNAK(&packet);
+ declined = 1;
+ break;
+ }
+ }
+ }
+ // BRCM_end
+
+ if (!declined) {
+ if (sendOffer(&packet) < 0) {
+ LOG(LOG_ERR, "send OFFER failed -- ignoring");
+ }