This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Simple direct advertising

Hello,

I'am trying to do directed advertisement with NRF51822 (Smart Beacon Kit pca20006). I don't have any previous connection with peer, its address is hard-coded. The goal is to hide advertisement to others and not to connect with the peer (the ultimate goal would be to have something like describe in the privacy message sequence charts of S132 but with S130)

I have tried to modified the "ble_app_beacon" example from SDK12 with S130 softdevice. Here is the modification I did :

ble_gap_addr_t     peer_addr = {BLE_GAP_ADDR_TYPE_PUBLIC,{0x19,0x75,0xAE,0xEB,0x27,0xB8}};

// B8:27:EB:AE:75:19 => RPi 

memset(&m_adv_params, 0, sizeof(m_adv_params));

m_adv_params.type        = BLE_GAP_ADV_TYPE_ADV_DIRECT_IND;
m_adv_params.p_peer_addr = &peer_addr; 
m_adv_params.fp          = BLE_GAP_ADV_FP_ANY;
m_adv_params.interval    = 0;
m_adv_params.timeout     = 0;

These are the only modifications I did (there is still the "p_manuf_specific_data" in the "ble_advdata_t" field.) When I flash the beacon, I don't have the red led blinking (like it was without modification) and can't see any advertising. I am doing something wrong? Would you recommend to use the ble_advertising module instead?

  • I would be interested to know how you can hide a advertisement and yet for it still to be useful.

    Something must be capable of receiving your advertisement otherwise the system would be useless.

    If you just want to send some sort of non-standard advertising data, I think you're going to need to build the advertising packet yourself and call the lower level functions in the API and not call functions like ble_advdata_set()

  • As far as I understood, direct advertisement should be ignored by a central scanner which address doesn't match the peer_address. So for a not too curious central the advertisement is "hidden". In my application the main goal is to know if a node is advertising or not. For this purpose, I want to "hide" my advertisements from others central than mine to avoid someone replicate my advertisement and make my central believe a beacon is alive.I know this is a very basic security scheme, but this is only a first step!

  • Very interesting,

    This sort of question has been asked before.

    devzone.nordicsemi.com/.../

    The answer does not say if its possible to hide the advertising

    Also see this link , it mentions directed advertising, but it doesnt say its hidden

    blog.bluetooth.com/.../

    I would interested to hear an official response to this security question, because DDOS of BLE devices could become a serious problem with the advert of the Web BLE API as browsers will be able to mount DOS attacks, as its simple to trick users into allowing the browser to access the BLE hardware

  • I see you have set the interval to 0, which means you are enabling directed advertising with high duty cycle, this shall per spec only last for 1.28 s, then maybe you start the "normal" advertising when you get the advertising timeout event? See this for more information.

    Yes, centrals should ignore directed advertisments that is not destined for them, but "curious" centrals wouldn't care about this.

  • Petter

    Can android or iOS behave as "curious" centrals. Perhaps iOS would not, but I'm not sure about android, or perhaps BLE devices like the CC2541 or CSR devices etc ,may have modes to be "curious" ??

Related