简体   繁体   English

从公共移动应用程序收集数据

[英]Collecting Data from public mobile application

I'll like to collect information from a mobile application I created. 我想从我创建的移动应用程序中收集信息。 The app allow users to use it without authentication and also I'll like to collect the data to highly-available service such as AWS SQS so I'll not miss any data. 该应用程序允许用户无需身份验证即可使用它,而且我想将数据收集到高可用性服务(例如AWS SQS)中,因此我不会丢失任何数据。
The application is always connected to the internet so no need for offline collection of the data. 该应用程序始终连接到Internet,因此无需脱机收集数据。

What bother me is how can I send the data in a secure manner so that users will not be able to send fake data into the same endpoint I'm using. 让我困扰的是如何以安全的方式发送数据,以使用户无法将伪造的数据发送到我正在使用的同一端点。

Google Analytics is not fit here because I need access to the raw data, not only aggregate of it. Google Analytics(分析)不适合此处,因为我需要访问原始数据,而不仅仅是原始数据。

You should look into STS for getting temporary access credentials from your app instead of hard coding AWS credentials into your app. 您应该研究STS来从应用程序中获取临时访问凭证,而不是将AWS凭证硬编码到应用程序中。

The fact that your application does not require authentication does not necessarily mean you are at an increased likelihood of having a malicious actor send bad data to your service. 您的应用程序不需要身份验证的事实并不一定意味着您增加了恶意行为者向您的服务发送错误数据的可能性。 If your app had authentication it would still be possible for a malicious actor to reverse engineer the requests and send bad data using the authenticated credentials. 如果您的应用程序已通过身份验证,则恶意行为者仍然有可能对请求进行反向工程并使用经过身份验证的凭据发送错误数据。

While sending data directly to SQS is a valid option, you could also send the data into SNS if you want to have the ability to fan out to multiple systems such as multiple SQS queues. 将数据直接发送到SQS是有效的选择,但是如果您希望能够将数据扇出到多个系统(例如多个SQS队列),则也可以将数据发送到SNS。

You could also look into using API Gateway + Lambda as the service that is called from your app even if the Lambda function only sends the data to SQS as this would allow for additional processing flexibility in the future such as validating input with additional logic before it is sent to SQS. 您还可以考虑使用API​​网关+ Lambda作为从您的应用程序中调用的服务,即使Lambda函数仅将数据发送到SQS也是如此,因为这将在将来提供额外的处理灵活性,例如在输入之前使用其他逻辑来验证输入发送到SQS。 However, this type of logic could just as easily be performed when the messages are pulled off the queue. 但是,将消息从队列中拉出时,可以很容易地执行这种逻辑。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM