Securing Your AngularJS Applications #AngularJS #By Sayed Ahmed

Securing Your AngularJS Applications
Some security measures can be as follows:
Take security measures at the entry and exit points of data to and from the server
Secure the server and prevent unauthorized access to data, and HTML
Encrypt the connection i.e https://
Prevent cross-site scripting (XSS),
Prevent cross-site request forgery (XSRF) attacks
Block JSON injections

AngularJS Templates Securing:
$templateCache caches templates. If you want to use this, you need to remove the cache for each user login

The following or similar stuff can help
Cache-Control: no-cache, no-store, must-revalidate
Pragma : no-cache
Expires : 0

using https can address the snooping and man in the middle attack

You need to prevent JSON Injection Vulnerability
to do this, you can add )]}’, before your JSON, though not valid JSON but helps to prevent JSON injection vulnerability.

Prevent XSS attack in the client side
AngularJS escapes all HTML in text that is displayed through the ng-bind directive, or template interpolation (that is text in {{curly braces}}). From: http://sitestree.com/?p=846
Categories:AngularJS, By Sayed Ahmed
Tags:
Post Data:2014-02-15 23:59:48

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Building Your Own Directives in AngularJS #AngularJS #By Sayed Ahmed

Building Your Own Directives
Directives can appear as HTML elements, attributes, comments, or CSS classes. Examples
<my-directive></my-directive>
<input my-directive>
<!– directive: my-directive–>
<input>

Defining a Directive
angular.module(‘app’, []).directive(‘myDir’, function() {
return myDirectiveDefinition;
});

Writing a Button Directive
escribe(‘button directive’, function () {
var $compile, $rootScope;
beforeEach(module(‘directives.button’));
beforeEach(inject(function(_$compile_, _$rootScope_) {
$compile = _$compile_;
$rootScope = _$rootScope_;
}));

it(‘adds a “btn” class to the button element’, function() {
var element = $compile(‘<button></button>’)($rootScope);
expect(element.hasClass(‘btn’)).toBe(true);
});
});
});

Using the button directive
<button type=”submit”
>Click Me!</button>

Implementing a Custom Validation Directives
Implementing a custom validation directive

Now we have our tests in place, so we can implement the functionality of the directive:

myModule.directive(‘validateEquals’, function() {
return {
require: ‘ngModel’,
link: function(scope, elm, attrs, ngModelCtrl) {
function validateEqual(myValue) {
var valid= (myValue === scope.$eval(attrs.validateEquals));
ngModelCtrl.$setValidity(‘equal’, valid);
return valid ? myValue : undefined;
}

ngModelCtrl.$parsers.push(validateEqual);
ngModelCtrl.$formatters.push(validateEqual);

scope.$watch(attrs.validateEquals, function() {
ngModelCtrl.$setViewValue(ngModelCtrl.$viewValue);
});
}
};
}); From: http://sitestree.com/?p=844
Categories:AngularJS, By Sayed Ahmed
Tags:
Post Data:2014-02-16 10:00:57

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Optimizing AngularJS Page Loading #AngularJS #By Sayed Ahmed

Optimizing AngularJS Page Loading:

Optimizing web-applications for faster performance often include reducing network activities, reducing send and receive requests over the network/internet, and reducing data downloads. Minification of JavaScript, CSS, and HTML files can help with that. AngularJS kind of forces to write minification safe JavaScript, and writing array style and annotation based function declaration is recommended.

Creating partial templates and loading related templates in combination may help. Probably, need some experiment and planning before than doing it on the fly. Two ways to preload templates 1. <script> tag 2. $templateCache

You may want to read one of our other articles on optimising landing pages for AngularJS single page applications by using ng-cloak, and ng-bind.

Using Asynchronous script loader such as Require.Js does not improve the performance a lot [according to the book as listed in the reference section]. Hence, so far, AMD is not recommended with AngularJS.

You can check how to use Require.JS in your applications at : http://requirejs.org/docs/start.html . You may want to use them in non-AngularJS projects. The idea is, you have to have a consistent project directory structure esp for JavaScript files as recommended and specified by Require.Js. In your, HTML file you refer to the main.js file, single entry point for loading JS code. In that main.js, you will use Require.JS esp. require() to load other JS files asynchronously and as required by your application.

To use Require.JS with JQuery, you can check the following resource. The adoption may need different considerations for a new project or for adapting existing code for Require.JS
http://requirejs.org/docs/jquery.html From: http://sitestree.com/?p=836
Categories:AngularJS, By Sayed Ahmed
Tags:
Post Data:2014-02-15 23:43:41

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Resources Recently Checked on AngularJS and Java EE #AngularJS #By Sayed Ahmed #Java SE – Java EE #Misc. Reading

Resources on AngularJS and Java EE, Sure, I did check them...

http://www.journaldev.com/3633/hibernate-interview-questions-and-answers

 
http://www.journaldev.com/3626/hibernate-validator-jsr303-example-tutorial


https://scotch.io/bar-talk/s-o-l-i-d-the-first-five-principles-of-object-oriented-design

http://stackoverflow.com/questions/49002/prefer-composition-over-inheritance

http://stackoverflow.com/questions/3058/what-is-inversion-of-control

http://stackoverflow.com/questions/242177/what-is-aspect-oriented-programming

https://angular.io/docs/ts/latest/cookbook/a1-a2-quick-reference.html

https://docs.oracle.com/javase/tutorial/java/IandI/abstract.html

http://www.corej2eepatterns.com/images/CJP2Catalog.gif

Aspect Oriented Programming:
http://docs.spring.io/spring/docs/current/spring-framework-reference/html/aop.html

http://www.journaldev.com/2394/java-dependency-injection-design-pattern-example-tutorial

http://www.journaldev.com/2583/spring-aop-example-tutorial-aspect-advice-pointcut-joinpoint-annotations

Angular:
https://angular.io/docs/ts/latest/cookbook/a1-a2-quick-reference.html

http://career.guru99.com/top-25-angular-js-interview-questions/

https://www.toptal.com/angular-js/interview-questions

http://www.tutorialspoint.com/angularjs/angularjs_interview_questions.htm

https://netbeans.org/downloads/

http://draptik.github.io/blog/2013/07/13/angularjs-example-using-a-java-restful-web-service/

https://www.toptal.com/java/building-modern-web-applications-with-angularjs-and-play-framework

https://www.youtube.com/watch?v=2B3qL7XtKnE
http://www.ibm.com/developerworks/websphere/library/techarticles/1602_woolf-trs/1602_woolf2.html

Java Versions:
https://en.wikipedia.org/wiki/Java_EE_version_history

Angular and Java
https://www.youtube.com/watch?v=2B3qL7XtKnE

http://iloveoracle.com/consulting-book-review-the-nomadic-developer-surviving-and-thriving-in-the-world-of-technology-consulting/

https://www.toptal.com/nodejs/interview-questions

https://gun.io/blog/tutorial-deploy-node-js-server-with-example/

https://confluence.atlassian.com/doc/integrating-jira-and-confluence-2825.html

https://en.wikipedia.org/wiki/Confluence_(software)

From: http://sitestree.com/?p=3826
Categories:AngularJS, By Sayed Ahmed, Java SE – Java EE, Misc. Reading
Tags:
Post Data:2016-08-08 15:01:31

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Angular.JS resources : Related JavaScript framework Stuff #AngularJS #By Sayed Ahmed #Misc. Reading

Why Angular? and Why not Angular

10 reasons why use angular?
http://www.sitepoint.com/10-reasons-use-angularjs/

Why Does Angular.js Rock?
http://angular-tips.com/blog/2013/08/why-does-angular-dot-js-rock/

Check the total article and esp the section: Why not Angular, Why not Backbone, Why not Ember https://moot.it/blog/technology/frameworkless-javascript.html

 

These articles do worth reading: http://angular-tips.com/blog/archives/

 

Bite-sized web development training with AngularJS.

https://egghead.io/

 

Mastering Web Application Development with AngularJS

 

  From: http://sitestree.com/?p=710
Categories:AngularJS, By Sayed Ahmed, Misc. Reading
Tags:
Post Data:2014-01-26 21:14:12

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Introduction to project management using dot project 2 #AngularJS #Management

https://www.youtube.com/watch?feature=player_embedded&v=f74lpJ5Y_eU From: http://sitestree.com/?p=2614
Categories:AngularJS, Management
Tags:Project Management
Post Data:2015-10-18 06:39:16

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

english database management system #AngularJS #Management #Data Warehouse

https://www.youtube.com/watch?feature=player_embedded&v=nvY99QcsktM From: http://sitestree.com/?p=2612
Categories:AngularJS, Management, Data Warehouse
Tags:database, management
Post Data:2015-10-18 00:25:18

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

Linux Bash Commands A to Z #AngularJS #RHCSA

https://www.youtube.com/watch?feature=player_embedded&v=8tMkRQo_2GU From: http://sitestree.com/?p=2596
Categories:AngularJS, RHCSA
Tags:AngularJS, Linux, Command
Post Data:2015-10-16 06:49:38

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

bengali search engine optimization google webmaster tools #Bengali Literature

https://www.youtube.com/watch?feature=player_embedded&v=L2lcdMn67Xs From: http://sitestree.com/?p=2616
Categories:Bengali Literature
Tags:Bengali, search engine optimization, google webmaster
Post Data:2015-10-18 12:43:39

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada

bangla course curriculam grade 9 10 computer study #Bengali Literature

https://www.youtube.com/watch?feature=player_embedded&v=Nt5gvRdLLdM From: http://sitestree.com/?p=2606
Categories:Bengali Literature
Tags:
Post Data:2015-10-17 06:10:48

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada