2

For a school face recognition project, I bought a DLINK DCS-5000L IP Camera.

I had the staff - theoretical - approval beforehand, but now that I am trying to install it, they are making it more difficult than expected.

Initially, the setup planned (assuming approval on all levels) was:

  1. install the camera in the classroom
  2. configure port forwarding on the school's router in order to access the data from outside
  3. configure surveillance station to store that data on my home Synology NAS

However, things are not turning as easy as expected: they are ok for me to set it up as long as it doesn't involve touching the school's router. Instead, they suggested that I bring my own.

So my question is: How can I setup the recording of the video stream without physical access to their router?

If needed, I can bring from home:

  • a DSL router (incidentally, also a D-LINK)
  • a cheap wifi extender that has an ethernet port
  • an external hard drive (in case remote access is not a possibility at all)

To make my questions more specific:

  • can I create a subnetwork with my DSL router (or range extender), and connect it to the School's network? (ethernet or wifi accesses are available)
  • how can I setup the recording of the video stream to a device outside the school? (or if not possible on a hard drive connected to the router)

Your patience will be appreciated as I have no experience setting up a surveillance camera or a subnetwork.

Thanks very much

9
  • 23
    Security and 'getting it to work' aside, if that data is stored anywhere (and probably even when not, I'm not a lawyer), there may be privacy violations. You might want to ask whoever is carrying the final responsibility for the project (which isn't you) whether this is such a good idea.
    – Mast
    Dec 25 '18 at 22:00
  • 3
    Consider grabbing some sample videos from the camera locally, and then save those to disk and process them for your project. Don't be live-streaming, for your safety.
    – Criggie
    Dec 25 '18 at 22:16
  • 17
    Could you clarify what country you are in and what level of schooling this is? I've taught in schools in the UK and am also a parent to children in primary school and I am extremely surprised you got any agreement to live stream from a classroom for any sort of project. My gut instinct here is that the person who gave you the initial permission unfortunately wasn't someone who had the authority to do so or understand the implications of what they were agreeing to. For the avoidance of doubt, I love your enthusiasm but this would not happen in my classroom, I suggest finding another way. Dec 25 '18 at 22:31
  • 3
    I just have to chime in and say that this sounds highly illegal. At least in the US. Depending on school level you can run afoul of TONS of legal issues revolving around privacy, minors, recording video etc. Some of which are straight up felonies. Even if it goes unprosecuted, the school is likely to CYA in a manner that leaves you liable, and "out in the rain". Different laws for different areas though, but be very careful.
    – coteyr
    Dec 26 '18 at 3:09
  • 2
    Even without minors, without GDPR and without storing the data, this is super high risk in Europe. It depends on where exactly you are, but in some countries it is outright illegal (in a "felony" sense, not in a "regulatory offense" sense) to even attempt to record footage of a (non-prominent) person, except under very specific conditions. You really, really, really want to consult a lawyer before proceeding. That is, a real lawyer, not some random person on the internet.
    – Damon
    Dec 26 '18 at 13:43
8

configure port forwarding on the school's router in order to access the data from outside

[…] they are ok for me to set it up as long as it doesn't involve touching the school's router. Instead, they suggested that I bring my own.

As long as you're still connecting through the school router, this was a useless suggestion. Routers are not magic; it does not matter what kind of device you connect to the school's router – whether it's a camera or a second router – it behaves the same with regards to port-forwarding. If it's impossible to connect from outside to your camera, then it'll remain equally impossible to connect from outside to your router.

(A subnetwork can be created – indeed that's what routers do – but it won't change the situation in any way.)


You can probably still use the camera and the surveillance station, but you'll be limited to outgoing connections only. For example, you could put the recording device in the same school network as the camera is – internal connections within a decently managed network do not need port-forwarding. (But if that doesn't work, then you can bring your own router/switch to connect the two directly.)

(The camera appears to support automatic NAT passthrough using D-Link's "mydlink" cloud service, but that's probably limited to access from the smartphone apps only.)

An alternative approach is to bring in a router or a raspberry pi that connects out to a VPN server (e.g. OpenVPN to your NAS) – and then your surveillance station will be able to connect in to the camera through the already-established VPN tunnel.

2
  • Thanks for replying, do you think the router mentioned in my question will allow connecting to the VPN? If so that would be a great solution
    – sousben
    Dec 25 '18 at 18:12
  • Search through its documentation. Some routers have VPN client features; yours probably does not. (But even if it was supported, it might not quite work in your situation; a plain Linux or OpenWRT or Mikrotik device would offer a bit more flexibility.)
    – user1686
    Dec 25 '18 at 18:29
5

Wireless IP security cameras may have two modes of operation. One would be a direct access mode where you connect directly to the IP address and capture a video stream via a number of supported, open protocols. Two would be a cloud based, central access provided by the manufacturer. In this case you and the camera connect to the server and you stream video via the third party server.

In the second case, you do not require port forwarding on the router. But you are constrained to the features the third party service provides, and your access to a direct video stream or recording may be limited. In the first case, you’ll need to port forward on the router but your access to the camera is at a lower level and you can typically do whatever you want with the video stream.

You’ll need to determine what modes your camera support and what exactly you need to do with the video stream.

As you have indicated, port forwarding is not an option. So if there is no cloud service available that suits your needs, you will need to setup connectivity internally at the school and do everything on-premise at the school.

What this looks like is, again, decided by your requirements. It’s entirely possible to simply hook up the camera to the network and stream the video to another network connected NAS, or PC.

There is one other possibility, and that is that your camera supports connecting “out” to some other device to write its video stream to. In this case, you could perform the port forwarding on your home router and have the camera send the data to you. However, there are several technical hurdles to this and security risks.

If this is a school project, assuming this is sanctioned by the school and instructor, and that it is for learning purposes, I would seek out the assistance and support of qualified staff members to complete your project. Butting heads with the support staff will not get you very far.

3

You may be able to use ngrok as a way to tunnel into the network externally without needing to forward ports.

You would need to look at the configuration and specifications to see which port to connect to, and then you just set ngrok to forward to the server on a different machine (in this case the server is running on the camera itself):

Forwarding to servers on a different machine (non-local services) ngrok can forward to services that aren't running on your local machine. Instead of specifying a port number, just specify a network address and port instead.

Example: Forward to a web server on a different machine

ngrok http 192.168.1.1:8080

For this to work you would need to find the IP of the camera once it is setup, so that you can forward traffic to it.

Then, instead of accessing the camera on the IP and port you have discovered, you would access it through the URL and port that the ngrok program assigns for you.

2
  • that sounds exciting, but do you think the firmware of the camera will allow installing third party software?
    – sousben
    Dec 26 '18 at 6:52
  • ngrok can be run on a separate machine (i.e. a desktop) and act as a proxy for the camera. The example in the answer shows how to do this. For connecting to port 8080 on the local machine (the one running ngrok) the command would instead be ngrok http 8080 Dec 26 '18 at 9:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.