We are submitting this issue to notify you of an IAM policy analysis we conducted based on an October 2021 copy of the shan18/Flash repository. We recognize that your application has continued to change since then, but wanted to share our results with you.
Analyzing inference/serverless.yml in https://github.com/shan18/Flash/tree/43868e9, we determined that the use of the s3:*wildcard permission in the provider-level iamRoleStatements definition resulted in over-privileged functions. By looking at the API calls that were actually being made by your application at that time, we determined that the following changes would reduce unnecessary privilege while still permitting the application to function:
High level overview:
The check and inference functions only need s3:GetObject permissions and the clean function needs s3:GetObject, s3:PutObject, and s3:DeleteObject permissions.
Your IAM policy was studied as part of a research project that was conducted jointly by researchers at the North Carolina State University and the University of Illinois at Urbana-Champaign. We developed an algorithm that leveraged graph reachability analysis to inspect privilege in serverless applications. This work has been accepted to appear at the 2024 Web Conference (Paper Title: “GRASP: Hardening Serverless Applications through Graph Reachability Analysis of Security Policies”). We will be discussing the results from our 2021 analysis of your application as part of this work, but will be sure to note that the policy has been updated since then.
If you’d like, we’d be happy to update our analysis to reflect the present state of your application. Do let us know if you have any thoughts or feedback.
Best,
Pubali Datta (co-authors: Isaac Polinsky, Adam Bates, Will Enck)
We are submitting this issue to notify you of an IAM policy analysis we conducted based on an October 2021 copy of the shan18/Flash repository. We recognize that your application has continued to change since then, but wanted to share our results with you.
Analyzing
inference/serverless.yml
in https://github.com/shan18/Flash/tree/43868e9, we determined that the use of thes3:*
wildcard permission in the provider-leveliamRoleStatements
definition resulted in over-privileged functions. By looking at the API calls that were actually being made by your application at that time, we determined that the following changes would reduce unnecessary privilege while still permitting the application to function:Note: the following policy changes use the https://github.com/functionalone/serverless-iam-roles-per-function serverless plugin to create detailed per-function iam policies.
High level overview: The
check
andinference
functions only needs3:GetObject
permissions and theclean
function needss3:GetObject
,s3:PutObject
, ands3:DeleteObject
permissions.Your IAM policy was studied as part of a research project that was conducted jointly by researchers at the North Carolina State University and the University of Illinois at Urbana-Champaign. We developed an algorithm that leveraged graph reachability analysis to inspect privilege in serverless applications. This work has been accepted to appear at the 2024 Web Conference (Paper Title: “GRASP: Hardening Serverless Applications through Graph Reachability Analysis of Security Policies”). We will be discussing the results from our 2021 analysis of your application as part of this work, but will be sure to note that the policy has been updated since then.
If you’d like, we’d be happy to update our analysis to reflect the present state of your application. Do let us know if you have any thoughts or feedback.
Best, Pubali Datta (co-authors: Isaac Polinsky, Adam Bates, Will Enck)