Skip to content

Commit 6dcc3b9

Browse files
committed
Merge branch 'hhristov/update-igx-ts-legacy-templates' of https://github.com/IgniteUI/igniteui-cli into hhristov/update-igx-ts-legacy-templates
2 parents 7021abf + a222937 commit 6dcc3b9

7 files changed

Lines changed: 32 additions & 10 deletions

File tree

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import javascript
2+
import semmle.javascript.security.dataflow.CommandInjectionCustomizations
3+
4+
5+
// General flow via config https://codeql.github.com/docs/codeql-language-guides/analyzing-data-flow-in-javascript-and-typescript/#sanitizers
6+
// Instead this follows https://github.com/github/codeql/blob/a3e9aed00ae5c1e70da8fbc4fc4a7cc803f177ca/javascript/documentation/library-customization.rst?plain=1#L244-L245
7+
// to modify the pre-defined javascript CommandInjection flow's Sanitizer
8+
9+
/**
10+
* Treat Util.sanitizeShellArg(x) as a sanitizer for shell‑command injection.
11+
*/
12+
class ShellArgSanitizer extends CommandInjection::Sanitizer {
13+
ShellArgSanitizer() {
14+
this.(DataFlow::MethodCallNode).getReceiver().toString() = "Util" and
15+
this.(DataFlow::MethodCallNode).getMethodName() = "sanitizeShellArg"
16+
}
17+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
name: igniteui-cli-custom-javascript-queries
2+
version: 0.0.0
3+
dependencies:
4+
codeql/javascript-queries: "*"

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ jobs:
4949
# By default, queries listed here will override any specified in a config file.
5050
# Prefix the list here with "+" to use these queries and those in the config file.
5151
# queries: ./path/to/local/query, your-org/your-repo/queries@main
52+
queries: ./.github/codeql/custom-queries-javascript
5253

5354
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
5455
# If this step fails, then you should remove it and run the build manually (see below)

packages/igx-templates/igx-ts-legacy/projects/_base/files/angular.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,8 @@
109109
"tsConfig": "tsconfig.spec.json",
110110
"inlineStyleLanguage": "scss",
111111
"assets": [
112-
"src/favicon.ico",
113-
"src/assets"
112+
"src/favicon.ico",
113+
"src/assets"
114114
],
115115
"styles": ["src/styles.scss"],
116116
"stylePreprocessorOptions": {

packages/igx-templates/igx-ts-legacy/projects/_base/files/src/app/app-routing-module.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@ import { UncaughtError } from './error-routing/error/uncaught-error';
66
import { ErrorRoutingModule } from './error-routing/error-routing-module';
77

88
export const routes: Routes = [
9-
{ path: 'error', component: UncaughtError },
10-
{ path: '**', component: NotFound } // must always be last
9+
{ path: 'error', component: UncaughtError },
10+
{ path: '**', component: NotFound } // must always be last
1111
];
1212

1313
@NgModule({
14-
imports: [RouterModule.forRoot(routes), ErrorRoutingModule],
15-
exports: [RouterModule, ErrorRoutingModule]
14+
imports: [RouterModule.forRoot(routes), ErrorRoutingModule],
15+
exports: [RouterModule, ErrorRoutingModule]
1616
})
1717
export class AppRoutingModule { }

packages/igx-templates/igx-ts-legacy/projects/_base_with_home/files/src/app/home/home.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ <h1>{{title()}}</h1>
33
<img src="assets/responsive.gif" alt="Ignite UI CLI">
44

55
<div id="linksContainer">
6-
<h3 class="links"><a target="_blank" rel="noopener" href="https://github.com/IgniteUI/ignite-ui-cli">Ignite UI CLI </a></h3>
7-
<h3 class="links"><a target="_blank" rel="noopener" href="https://www.infragistics.com/products/ignite-ui-angular">Component Demos</a></h3>
8-
<h3 class="links"><a target="_blank" rel="noopener" href="https://github.com/IgniteUI/igniteui-angular-ui-kits">Sketch UI Kit</a></h3>
6+
<h3 class="links"><a target="_blank" rel="noopener" href="https://github.com/IgniteUI/ignite-ui-cli">Ignite UI CLI </a></h3>
7+
<h3 class="links"><a target="_blank" rel="noopener" href="https://www.infragistics.com/products/ignite-ui-angular">Component Demos</a></h3>
8+
<h3 class="links"><a target="_blank" rel="noopener" href="https://github.com/IgniteUI/igniteui-angular-ui-kits">Sketch UI Kit</a></h3>
99
</div>

spec/unit/ts-transform/AngularTypeScriptFileUpdate-spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ import { RouterOutlet } from '@angular/router';
3838
styleUrl: './app.scss'
3939
})
4040
export class App {
41-
protected readonly title = signal('Home - IgniteUI for Angular');
41+
protected readonly title = signal('Home - IgniteUI for Angular');
4242
}
4343
`;
4444

0 commit comments

Comments
 (0)