Comments (5)
there is also another new feature in this: how many users are behind a proxy
from rtcstats-server.
Additional complication, strictly speaking you only want to honor these until you reach the first "untrusted" IP in the chain.
from rtcstats-server.
the public ip is the last one in the list -- we don't care about the previous chain :-)
from rtcstats-server.
That depends on whether or not you are concerned about people injecting random IPs. Probably not so much of an issue here, though.
from rtcstats-server.
since the repo is not public here is the interesting piece that needs to be ported:
const forwardedFor = upgradeReq.headers['x-forwarded-for'];
if (forwardedFor) {
const publicIPs = [];
const rawIPs = forwardedFor.split(',').map(ip => {
const publicIP = ['publicIP', null, ip.trim()];
obfuscate(publicIP);
publicIPs.push(publicIP[2]);
return ip;
});
const publicIP = ['publicIP', null, publicIPs];
tempStream.write(JSON.stringify(publicIP) + '\n');
process.nextTick(() => {
const city = cityLookup.get(rawIPs[rawIPs.length - 1]);
if (tempStream) {
tempStream.write(JSON.stringify({
0: 'location',
1: null,
2: city,
time: Date.now()
}) + '\n'
);
}
});
}
makes the (not necessarily valid) assumption that it always runs behind a LB
from rtcstats-server.
Related Issues (20)
- number of different host candidates in onicecandidate
- location features HOT 2
- feature: candidate types after ice restart HOT 1
- write peerconnections to different files HOT 4
- work with spec-stats HOT 3
- chrome 51 broke stuff
- receivingvideo10s is broken
- extractTrack should not rely on onaddstream HOT 3
- Ability to start/end session outside opening/closing tab HOT 2
- inconsistent internal use of .timestamp HOT 1
- move the repository HOT 5
- feature: delta(qp) HOT 2
- ipv6 obfuscation HOT 1
- fileFormat 2 breaks time series in webrtc-dump-importer HOT 2
- gcp/bigquery support HOT 5
- use materialized views
- maxmind postinstall won't work anymore HOT 3
- navigator.userAgent deprecation
- BigQuery ignore unknown values HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rtcstats-server.