Application assembly - spec#11148
Conversation
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
Signed-off-by: Reshma Abdul Rahim <reshmarahim.abdul@microsoft.com>
| func (g *BicepGenerator) GenerateToFile(result *dtypes.DiscoveryResult, opts BicepGenerateOptions, outputPath string) error { | ||
| // Ensure directory exists | ||
| dir := filepath.Dir(outputPath) | ||
| if err := os.MkdirAll(dir, 0755); err != nil { |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression High
| return fmt.Errorf("generating bicep: %w", err) | ||
| } | ||
|
|
||
| if err := os.WriteFile(outputPath, buf.Bytes(), 0644); err != nil { |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression High
| // Path: <category>/<typeName>/recipes/<provider> | ||
| recipesPath := fmt.Sprintf("%s/%s/%s/recipes/%s", s.baseURL, category, typeName, s.provider) | ||
|
|
||
| resp, err := s.httpClient.Get(recipesPath) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in network request Error Experimental
| // Path: <category>/<typeName>/recipes/<provider>/<templateKind> | ||
| url := fmt.Sprintf("%s/%s/%s/recipes/%s/%s", s.baseURL, category, typeName, s.provider, templateKind) | ||
|
|
||
| resp, err := s.httpClient.Get(url) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in network request Error Experimental
|
|
||
| func findDependency(deps []dtypes.DetectedDependency, id string) *dtypes.DetectedDependency { | ||
| for i := range deps { | ||
| if deps[i].ID == id { |
Check warning
Code scanning / CodeQL
User-controlled bypass of condition Warning Experimental
| score := 0.5 // Base score | ||
|
|
||
| // Exact resource type match | ||
| if recipe.ResourceType == resourceType { |
Check warning
Code scanning / CodeQL
User-controlled bypass of condition Warning Experimental
| func (m *Matcher) explainMatch(recipe Recipe, resourceType string) string { | ||
| var reasons []string | ||
|
|
||
| if recipe.ResourceType == resourceType { |
Check warning
Code scanning / CodeQL
User-controlled bypass of condition Warning Experimental
Description
Please explain the changes you've made.
Type of change
Fixes: #issue_number
Contributor checklist
Please verify that the PR meets the following requirements, where applicable: