text:
(co-sponsored) Convention for Higher Education (Brighton, 24-25 May)
Friday 24 & Saturday 25 May 2013
Organised by the Centre for Applied Philosophy, Politics and Ethics (CAPPE), University of Brighton, and co-sponsored by the Campaign for Public Universities, the Council for the Defence of British Universities, and the UCU at the University of Brighton, this two-day conference on Higher Education – What it is for, and how to defend it: towards a Charter for Higher Education in the UK investigates the current changes that British Higher Education (in England and Wales) isundergoing.
The Convention is designed to enable colleagues from the full range of university disciplines to address how to preserve a properly described 'higher education' from the effects of current proposals, and from the redefinition of universities and of higher learning. As a complement to the Council for theDefence of British Universities and the Campaign for Public Universities, it will consider, and adopt a draft of, a Charter for Higher Education that the organisers hope will be debated and refined in most or all institutions of higher learning throughout the UK, and which could then form the core of values around which colleagues could cohere, whether as members of Councils and Academic Boards, Faculty or School Boards, as members of their Course Committees, or as union members.
The Convention has been occasioned by the 25th anniversary of the Humanities Programme at the University of Brighton. Born in in adversity in 1988 — in the midst of an earlier assault on the Humanities — it has survived and thrived by resisting both governmental pressure and temporary fashions in education and pedagogy. It is an interdisciplinary, non-modular range of degree courses based on small-group teaching, and research-focused student development.
Priya Gopal, Colin Blakemore, John Holmwood, Martin McQuillan, Gill Scott, Will Hutton, Martin Hall, Luke Martell, Bob Brecher, Peter Scott, Tom Hickey, Colin Green, Caroline Lucas (MP), Thomas Docherty, Michael Rosen
a draft Charter for Higher Education
• The Ambit and Character of a University for the 21st Century
• What is Special about a Public University System
• Knowledge and Dissemination: the Commercialisation of Learning & Research
• Constraints and Conformities: Defining Economic and Social Engagement
• Academic Freedom: its Meaning in the New Century
• Work and Contracts in a Corporate University
• The Arts, Humanities and Social Sciences in Adversity: Governmental Myopia
• How Mass Higher Education Does Not Entail Lower Standards (Humanities at Brighton)
• Research Supervision: Craft or Mass Process?
• Of Education, Entertainment and Satisfaction: Student Evaluation vs the NSS
• Students, Staff and Democracy in the Academy
• The Bureaucratisation of Learning: aims, objectives, methods, outcomes
• Of Careers and Careerism – Who Benefits: the Equality Agenda
• Global HE as International Trade: Commerce and Contradiction
• Quantum of Recognition: Vacuities of Research Measurement
The registration fee for this event is £40 for employed delegates and £10 for students/retired/unemployed delegates. This includes lunch and refreshments on both days.
Online registration is available via the following link: http://shop.brighton.ac.uk/browse/extra_info.asp?compid=1&modid=2&prodid=166&d eptid=3&catid=11
For further information e-mail Bob Brecher at r.brecher@brighton.ac.uk
About the Keynote Speakers:
Colin Blakemore
Professor Colin Blakemore is a neurobiologist who is Professor of Neuroscience at the University of Oxford and at the University of Warwick, and who specializes in vision and the development of the brain. He is also a member of the Institute of Philosophy's Centre for the Study of the Senses at the University of London, and a founding member of the Council for the Defence of British Universities.
John Holmwood
Professor John Holmwood is a sociologist at the University of Nottingham who specializes in the relation between sociological theory and explanation, and between social stratification and inequality. He is currently working on issues of pragmatism in public sociology, and particularly on the role of the university within a system of moral economy. He is co-founder of the Campaign for the Public University.
Priya Gopal
Dr Priyamvada Gopal is Dean of Churchill College, Cambridge, where she teaches in the Faculty of English. Her work is in the area of colonial and postcolonial literatures, and their relation to British and American literatures, the novel, translation and gender and feminism. She also has an interest in Marxism and critical theory, and the politics and cultures of empire and globalisation. She has published works on literary radicalism inIndia, Postcolonial studies after Iraq, and the Indian English novel.
Martin McQuillan
Professor Martin McQuillan is a literary theorist and cultural critic, and is currently Professor of Literary Theory and Cultural Analysis, and Dean of the Faculty of Arts and Social Sciences at Kingston University, London, where he is also Co-Director of The London Graduate School. His work investigates the relations between literary theory, art theory, cultural studies and continental philosophy. He has written on Barthes, De Man, Spark, Derrida and Disney. He is a member of the Executive Committee of the Council for the Defence of British Universities.
Gill Scott
Gill Scott is Principal Lecturer in social history, whose research is concerned with the relationship between feminist ideas and the organisation of working-class women, particularly within the co-operative and labour movements. Her main focus has been the history of the Women's Co-operative Guild, an auxiliary body of the BritishConsumers' Co-operative movement, about which she has published several articles, and a monograph. She She was for many years the Course Leader of the degrees in the undergraduate Humanities Programme at Brighton.
Will Hutton
Will Hutton is a writer and weekly columnist for, and former editor-in- chief of, The Observer. He is currently Principal of Hertford College, Oxford, and Chair of the Big Innovation Centre, an initiative from The WorkFoundation where he was Chief Executive from 2000 to 2008. He is also a governor of the London School of Economics, visiting professor at the Manchester Business School and at the University of Bristol, and a visitingfellow at Mansfield College, Oxford. He has written on China and the West, globalization and capitalism, state and economy, and the relationship between Europe and the USA.
Martin Hall
Professor Martin Hall, a fellow of the Royal Society of South Africa, is an educationalist and ethnoarchaeologist who has written extensively on South African history, culture and higher education policy. He is currently Vice Chancellor of the University of Salford. He has written on affirmative action in South Africa and the USA, and on memory, repression and resistance.
Luke Martell
Professor of political sociology at the University of Sussex, Luke Martell works on globalization and social movements, technology, the media and globalised culture. He has also written on social democracy and on New Labour, and on the politics and sociology of environmentalism.
Bob Brecher
Professor of Moral Philosophy at the University of Brighton, where he is Director of the Centre for Applied Philosophy, Politics and Ethics, Bob Brecher, whose scholarly work commenced with the philosophy of religion, has recently developed a critique of Liberalism on the basis of a rationalist ethics. He has written on the pedagogies of liberation and resistance in the academy, and he is Course Leader of the MA in Applied Ethics.
Professor of Higher Education studies at the Institute of Education, and Chair of the Research Advisory Panel, Leadership Foundation for Higher Education, Peter Scott was previously Vice-Chancellor of Kingston University. He has also been Pro Vice-Chancellor for external affairs at the University of Leeds, as well as Professor of Education and Director of the Centre for Policy Studies in Education. He has been Chair of the Universities Association forLifelong Learning, and a member of the HEFCE Board. Before going to Leeds in 1992, he was for 16 years editor of the Times Higher Education Supplement.
Tom Hickey
Principal Lecturer in Philosophy and Political Economy at the University of Brighton, Tom Hickey is Course Leader of the MA Cultural and Critical Theory. He works on the relation between politics, aesthetics and representation, was joint organizer of the biennial 'Globalisation and Resistance' conferences, and conferences on holocausts and their denials both for the UCU and at the Brighton. He has published on issues of democracy and onaspects of South African art. He has been a member of the National Executive of the UCU since 2006, and is Chair of the UCU Coordinating Committee at the University of Brighton.
Colin Green
Professor Colin Green is Emeritus Professor of Surgery in the Division of Surgery and Interventional Science, University College London. He was the Director of the Northwick Park Institute for Medical Research, and founder of International Medical Educational Trust 2000, which trains healthcare workers in Gaza and the West Bank. He is currently UNESCO Chair of Cryobiology with the Ukraine Academy of Science.
Caroline Lucas (MP)
Member of Parliament for Brighton Pavilion since 2010, Caroline Lucas was leader of the Green Party from 2008-2012, and was a Member of the European Parliament for the South East (England) from 1999-2010. She is Vice-President of the RSPCA and the Stop the War Coalition, and is on the National Council of CND. An English Literature graduate from Exeter, where she also gained her doctorate, she campaigns and writes on green economics, localisation, alternatives to globalisation, trade justice, animal welfare and food.
Thomas Docherty
Professor Thomas Docherty publishes on English and comparative literature from the renaissance to the present, and specializes in the philosophy of literary criticism, critical theory and cultural history. Hisrecent interest has been in the area of cultural policy related to international higher education. He is currently working on two books, one on universities and the process of globalization, and the other on memory. He is on the Steering Committee of the Council for the Defence of British Universities.
Michael Rosen is a broadcaster, children's novelist and poet, and is Visiting Professor of Children's Literature at Birkbeck College, London. He was Children's Laureate from 2007 to 2009. Graduate of Wadham College, Oxford, he secured an MA in Children's Literature from Reading, and his doctorate from the University of North London. In the 1970s, he was victimized for his political views by the BBC under its then operational vetting procedure. He is Director of the Brighton Festival in 2013.


text:
'use strict';

/**
 * @ngdoc filter
 * @name ng.filter:filter
 * @function
 *
 * @description
 * Выбор из массива некоторых элементов и возврат их в новом массиве.
 *
 * Обратите внимание: Эта функция используется только для типа Array в выражениях Angular. Смотрите
 * {@link ng.$filter} для большей информацией об Angular массивах.
 *
 * @param {Array} array Входной массив.
 * @param {string|Object|function()} expression Основание для использования при выборе элементов из входного массива.
 *
 *   Может быть одним из:
 *
 *   - `string`: Если основание является подстрокой элемента входного массива, то этот элемент включается
 *     в результатирующий массив. Все строки или объекты со строковыми свойствами во входном массиве,
 *     которые содержат подстроку основания будут возвращены. Основание может быть с отрицанием, для этого
 *     нужно применить префикс `!`.
 *
 *   - `Object`: Объект-паттерн, который используется для фильтрации специфических свойств в объектах
 *     содержащихся в массиве. Например, основание `{name:"M", phone:"1"}` вернет массив с элементами,
 *     у которых имеется свойство name содержащее "M" и имеется свойство phone содержащее "1". Если
 *     в качестве имени использовать `$` (как в `{$:"text"}`) то в результате будут искаться все объекты
 *     у которых любое свойство содержит требуемое значение. Это эквивалент простому текстовому основанию,
 *     расмотренному чуть раньше.
 *
 *   - `function`: функция основания может быть использована для реализации собственной логики фильтрации.
 *     Эта функция вызывается для каждого элемента входного массива. В результате в выходном массиве будут
 *     только элементы, для которых эта функция вернет true.
 *
 * @param {function(expected, actual)|true|undefined} comparator Компаратор, который используется чтобы
 *     определить что ожидаемое значение (из фильтра) и фактическое значение (из объекта в массиве) равны.
 *
 *   Может быть одним из:
 *
 *     - `function(expected, actual)`:
 *       Функция, которая передаст значение объекту и значение основания для сравнения и должна вернуть true,
 *       если этот элемент должен быть включен в результат фильтрации.
 *
 *     - `true`: Короткая запись для `function(expected, actual) { return angular.equals(expected, actual)}`.
 *       которая означает строгое сравнение ожидаемого с имеющимся.
 *
 *     - `false|undefined`: Короткая запись функции, которая ищет подстроку без учета регистра.
 *
 * @example
   <doc:example>
     <doc:source>

       Search: <input ng-model="searchText">

Name	Phone

           {{friend.name}}
           {{friend.phone}}

       Any: <input ng-model="search.$">

       Name only <input ng-model="search.name">

       Phone only <input ng-model="search.phone"å>

       Equality <input type="checkbox" ng-model="strict">

Name	Phone

           {{friend.name}}
           {{friend.phone}}

     </doc:source>
     <doc:scenario>
       it('should search across all fields when filtering with a string', function() {
         input('searchText').enter('m');
         expect(repeater('#searchTextResults tr', 'friend in friends').column('friend.name')).
           toEqual(['Mary', 'Mike', 'Adam']);

         input('searchText').enter('76');
         expect(repeater('#searchTextResults tr', 'friend in friends').column('friend.name')).
           toEqual(['John', 'Julie']);
       });

       it('should search in specific fields when filtering with a predicate object', function() {
         input('search.$').enter('i');
         expect(repeater('#searchObjResults tr', 'friend in friends').column('friend.name')).
           toEqual(['Mary', 'Mike', 'Julie', 'Juliette']);
       });
       it('should use a equal comparison when comparator is true', function() {
         input('search.name').enter('Julie');
         input('strict').check();
         expect(repeater('#searchObjResults tr', 'friend in friends').column('friend.name')).
           toEqual(['Julie']);
       });
     </doc:scenario>
   </doc:example>
 */
function filterFilter() {
  return function(array, expression, comperator) {
    if (!isArray(array)) return array;
    var predicates = [];
    predicates.check = function(value) {
      for (var j = 0; j < predicates.length; j++) {
        if(!predicates[j](value)) {
          return false;
        }
      }
      return true;
    };
    switch(typeof comperator) {
      case "function":
        break;
      case "boolean":
        if(comperator == true) {
          comperator = function(obj, text) {
            return angular.equals(obj, text);
          }
          break;
        }
      default:
        comperator = function(obj, text) {
          text = (''+text).toLowerCase();
          return (''+obj).toLowerCase().indexOf(text) > -1
        };
    }
    var search = function(obj, text){
      if (typeof text == 'string' && text.charAt(0) === '!') {
        return !search(obj, text.substr(1));
      }
      switch (typeof obj) {
        case "boolean":
        case "number":
        case "string":
          return comperator(obj, text);
        case "object":
          switch (typeof text) {
            case "object":
              return comperator(obj, text);
              break;
            default:
              for ( var objKey in obj) {
                if (objKey.charAt(0) !== '$' && search(obj[objKey], text)) {
                  return true;
                }
              }
              break;
          }
          return false;
        case "array":
          for ( var i = 0; i < obj.length; i++) {
            if (search(obj[i], text)) {
              return true;
            }
          }
          return false;
        default:
          return false;
      }
    };
    switch (typeof expression) {
      case "boolean":
      case "number":
      case "string":
        expression = {$:expression};
      case "object":
        for (var key in expression) {
          if (key == '$') {
            (function() {
              if (!expression[key]) return;
              var path = key
              predicates.push(function(value) {
                return search(value, expression[path]);
              });
            })();
          } else {
            (function() {
              if (!expression[key]) return;
              var path = key;
              predicates.push(function(value) {
                return search(getter(value,path), expression[path]);
              });
            })();
          }
        }
        break;
      case 'function':
        predicates.push(expression);
        break;
      default:
        return array;
    }
    var filtered = [];
    for ( var j = 0; j < array.length; j++) {
      var value = array[j];
      if (predicates.check(value)) {
        filtered.push(value);
      }
    }
    return filtered;
  }
}

redpajama_set_name: RedPajamaGithub


text:
Black Mirror: The Twilight Zone successor
Dyllan E. x Jan 11th '18
The beauty of cinema, the true beauty, is it's undeniable ability to make audience members feel. It's talent to extract those who dare to put themselves before it for however long (2 minutes, 20 minutes, or even 3 hours), and place them in a comatose state of awe. This is what makes this art so well loved. Through series of compelling stories displayed, you can find this self reflection of the current world you live in. Television in many ways is no different; often shorter though. The lines have been blurred to the point where it has become more difficult to determine the difference between a television series and a cinematic film. Now, fusing that cinematic element, television as of lately has found a way to introduce more originality by telling more personal stories that audiences can connect to on exclusive levels. Releasing its fourth season on December 29th, Black Mirror has found a way to captivate audiences with the "what if?"
Using each stand alone story to tell a form of social commentary in very authentic and intricate ways, almost daring the viewer to pull away from whatever device they are watching from. The honesty and truth delivered from each story allows the viewer to take the situation and be able to place themselves in a science fiction fantasy world. These traits are the main reasons it has become one of the most important shows of this generation. This ability to do what it does to viewers, and be what it is at its level is breathtaking. However, it is far from the first to introduce this style. There are many to give this style off, but as with most great things, there truly can only be one."That one" is Rod Serling's brainchild, The Twilight Zone.
Yes, the argument can be made that Alfred Hitchcock Presents introduced a similar concept first, but in the end, the difference is in the execution of showmanship. When The Twilight Zone released, it sent audiences not into peril, but this alternate form of wonder. It gave profound statements on the human condition; for example: fear. The Twilight Zone played on fear exceptionally well, and at the time when the red scare was at its height, there was nothing but paranoia. Schools were flooded with public service announcements warning children and parents about the dangers that were in the world today; this era destroyed the wholesome image that came with the baby boomer era.
In Season 3 of The Twilight Zone, there was an episode called "The Shelter," and in this episode, a collection of neighbors gather in a household to celebrate the retiring of their dear friend, Bill Stockton. Only for the night to be ruined by an announcement that unidentified flying objects are making their way to the United States. Trembling in uncontrollable terror, the families disperse back to their homes in search of a haven. For the man of the hour, Dr. Bill Stockton, it was no more than a test for what he been preparing for; he had his family run to the bomb shelter he had been constructing. It wouldn't be long before many would come to the conclusion that they were not as safe as Bill and his family; madness spreads like a virus. The neighbors run to Bill's basement proceeding to demand he open the door, and let them in. By the end of the episode, they've torn the door down not only risking Bill and his family, but themselves as well. Once it is proven to be a false alarm, they are forced to reflect on how much they really knew about the people they call their loved ones. The depth in their aftershock is what made this episode so powerful. The revelation that while we may portray one thing, fear has this strength to claw nonstop until one's mask comes off, revealing just what truly is on the inside.
Continuing with the same theme, Black Mirror has shown the same ability. In a recent episode, "Arkangel" directed by Jodie Foster (on the new season), it does justice to keep this feeling alive even though it is not the best episode in the series. In this age, it can be frightening to be a parent because you are always wondering what your children might be consuming when you are not around. This one takes that, and raises the bar with the what if you could. An overprotective mother goes out on a limb, and has a chip installed in her daughter so that she would be able to see everything her child does. This also comes with the ability to censor everything her child sees; this then shows the negative side of just why too much censoring could be bad as she becomes numb. She feels less because she understands less. While Black Mirror has far more deep-seated episodes, this one does its job on keeping pace with the rest of the series.
A common theme one could find in both The Twilight Zone and Black Mirror is the overreliance on technology. The obsession with it, and it's advancement is a curious case going as far back to the Titanic, where man was willing to place full faith in machine. For these shows, viewers are more than the audience, they are characters because so often you can see yourself or someone you may or may not know.
I will add, while we may love The Twilight Zone as dearly as we do, it would be best to allow it to reside in its prime state; leave it as we remember it. There is no need to revive Rod Serling's brainchild as its illegitimate child has done a wonderful job resurfacing this ability on its own merits. It's better than the remakes.
-Dyllan Ellis
beauty in cinema black mirror rod serling Sci Fi television The twilight zone
Post Trump Art in Film and the Wonder Woman Renaissance
Jack White Releases Two New Songs

redpajama_set_name: RedPajamaCommonCrawl


text:
Q: Can't create CSRF token with Spring Security I am using Spring Security 3.2.3 in my Spring MVC application and getting some unexpected behavior.
According to the documentation here, it should be possible to use ${_csrf.token} in the meta tags of my html:
<meta name="_csrf" content="${_csrf.token}" />
<!-- default header name is X-CSRF-TOKEN -->
<meta name="_csrf_header" content="${_csrf.headerName}" />

From where I extract the value of "content" using JQuery and place it into the Request Header using AJAX.
For some reason though, Spring Security doesn't "convert" this into an actual token, it just gets sent into the header as a literal string "${_csrf.token}".
Trying the alternate route of using ${_csrf.token} in a hidden input according to the documentation, I then tried to check what the token evaluates to by checking the input's value, but it's still just plain text "${_csrf.token}".
Since it seems that Spring Security isn't in effect, am I missing some kind of configuration? I am currently using a barebones Spring Security Java configuration (as opposed to xml) as shown here:
import org.springframework.context.annotation.*;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.*;

@Configuration
@EnableWebSecurity
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {

    @Override
    protected void configure(HttpSecurity http) throws Exception {
        http
          .csrf();
      }
}

I know configure is getting called since I put a debug statement in it, so I assume that CSRF protection is indeed enabled since it should be by default.
I realize that the syntax "${}" is JSP Expression Language, and I am currently successfully using it to evaluate the context into an object with Thymeleaf, for example:
th:object="${context}"

So I tried adding "th:" in front of the meta tag's "content" like so:
<meta name="_csrf" th:content="${_csrf.token}"/>

But it results in an exception that this cannot be evaluated:

Exception evaluating SpringEL expression: "_csrf.token"

I think the key here may be figuring out how to get the expression to evaluate properly in my view.

A: I started with the same source article as you, I think, and the same "you should be able to" add answers as you did.   I fought it a different way. I made Thymeleaf give me the answer I wanted.
<meta name="_csrf" th:content="${_csrf.token}"/>
<!-- default header name is X-CSRF-TOKEN -->
<meta name="_csrf_header" th:content="${_csrf.headerName}"/>

Thymeleaf put the attribute "content" with the requested Spring EL contents.  I then used the provided JavaScript/JQuery to extract the info from the meta tags straight into the CSRF header.

A: Before adding the thymeleaf-extras-springsecurity namespace and its dependency into my project, I had similar problems.  I never did get the meta tags to work, even with thymeleaf-extras-springsecurity.  But I did successfully retrieve Spring Security's csrf token using the hidden input.  I have instructions below that work for me:
In the html tag, add:
xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4"
In your pom.xml (if you're using Maven) you'll need to add the dependency: thymeleaf-extras-springsecurity4.
Then add the hidden input inside your page's body to retrieve the csrf token.
<input type="hidden" id= "csrf-token" th:name="${_csrf.parameterName}" th:content="${_csrf.token}" />
and then use that within your javascript/jquery as follows:
function f1() {
    var token1 = $('input#csrf-token').attr("content");
...
    $.ajax({
...
        type: "POST",
        beforeSend: function (request)
    {
        request.setRequestHeader("X-CSRF-TOKEN", token1);
    },
...

This all assumes that you have spring security enabled, and that you have NOT turned off csrf protection.

A: I finally solved this problem, but it basically required rewriting Spring Security. Here it is in all its glory.
First, I followed the suggestions in Eyal Lupu's great blog post here, but I had to tweak it to my situation because of my AJAX requirement.
As for the Thymeleaf situation, the key tidbit is hidden away in the archives of the Thymeleaf forums - Infamous Issue 7.
https://github.com/thymeleaf/thymeleaf-spring/issues/7#issuecomment-27643488
The last comment by the creator of Thymeleaf himself says that:

th:action ... detects when this attribute is being applied on a
  tag --which should be the only place, anyway--, and in such case
  calls RequestDataValueProcessor.getExtraHiddenFields(... ) and adds the
  returned hidden fields just before the closing  tag.

That was the key phrase I needed to get the token to work. Unfortunately it's completely not obvious why th:action would also kick off getExtraHiddenFields, but at any rate it does, and that's what matters.
So for anyone struggling with Thymeleaf + Spring Security CSRF + AJAX POST, here are my steps (this is paring it down quite a bit but these are the high-level concepts to solve it):

*

*Implement the Spring interface RequestDataValueProcessor and register it in Spring Security's XML config so you can override the method getExtraHiddenFields, which allows you to insert a hidden input field into the HTML (with the token of course). The token itself is generated with a Java.Util UUID.

*With JQuery, read the value from that hidden field and set the Request Header's "X-CSRF-Token" attribute so that it gets sent over HTTP. It's not possible to simply leave the token in the hidden input field because we are not doing a form Submit, instead we use AJAX POST to call methods on the server side.

*Extend Spring's HandlerInterceptorAdapter and register it as an interceptor so that every time a POST method is done, the "preHandle" method on the server side is called so it can compare the request token (extracted from the HTTP header in the previous step) to the session's token (should be the same!). After it does this check, it can either allow the request to go through or return an error.

A: You have incorrect configuration for springSecurityFilterChain in your web.xml. Correct definition is:
<filter>
    <filter-name>springSecurityFilterChain</filter-name>
    <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>

Spring Security uses set of servlet filters to provide the functionality it is offering (including CSRF protection). These filters are defined as Spring beans (i.e. they are instantiated and managed by Spring application context). DelegatingFilterProxy is a special type of servlet filter, which finds root application context on the registered servlet context and delegates every call to the same named bean.

A: Your issue is a different one, just stumbled across this one as well and it took me several hours to figure out the cause. The cause for the issue described by you is that you did not enable csrf support within your spring-security.xml
This little snippet needs to go into your security-config.xml:

<!-- Static resources such as CSS and JS files are ignored by Spring Security -->
<security:http pattern="/static/**" security="none" />

<security:http use-expressions="true">

    <!-- Enables Spring Security CSRF protection -->
    <security:csrf/>

    <!-- Configures the form login -->
    <security:form-login
            login-page="/login"
            login-processing-url="/login/authenticate"
            authentication-failure-url="/login?error=bad_credentials"
            username-parameter="username"
            password-parameter="password"/>
    <!-- Configures the logout function -->
    <security:logout
            logout-url="/logout"
            logout-success-url="/login"
            delete-cookies="JESSIONID"/>
    <!-- Anyone can access these urls -->
    <security:intercept-url pattern="/auth/**" access="permitAll"/>
    <security:intercept-url pattern="/login" access="permitAll"/>
    <security:intercept-url pattern="/signin/**" access="permitAll"/>
    <security:intercept-url pattern="/signup/**" access="permitAll"/>
    <security:intercept-url pattern="/user/register/**" access="permitAll"/>

    <!-- The rest of our application is protected. -->
    <security:intercept-url pattern="/**" access="hasRole('ROLE_USER')"/>

    <!-- Adds social authentication filter to the Spring Security filter chain. -->
    <security:custom-filter ref="socialAuthenticationFilter" before="PRE_AUTH_FILTER" />
</security:http>
....
...
..
.

Save time by configuring this correctly...
Cheerio,
Flo!

A: In case you don't need to use Thymeleaf, I'd suggest the following:

*

*Add this to the top of your page:
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

*Add this to your login form:
<input type="hidden" name="${_csrf.parameterName}" value="${_csrf.token}" />

*Add these dependencies to your pom.xml:
<dependency>
    <groupId>org.apache.tomcat.embed</groupId>
    <artifactId>tomcat-embed-jasper</artifactId>
    <scope>provided</scope>
</dependency>
<dependency>
    <groupId>javax.servlet</groupId>
    <artifactId>jstl</artifactId>
</dependency>

After struggling a lot, that worked for me.

redpajama_set_name: RedPajamaStackExchange


Better-than-average American bar and bistro food.
: Because Coastal Flats has found its niche, the best advice is this: come early, or make a reservation, and either way, you may have to wait. This eatery, twin to its counterpart in Fairfax, has become an acknowledged source of well-prepared American staples, from cheeseburgers to platters of sautéed shrimp and creamy grits. Because the dinner and lunch menus are virtually the same, you can be sure to fit in either a calorie-conscious grilled salmon salad or satisfy the inner glutton with an order of low country beef-back ribs with a side of redskin mashed potatoes. We also enjoy the shrimp roll, really a meal in itself. No visit here would be complete without a wedge of the Key lime pie, but there's also banana pudding with caramel and chocolate sauces, a modern-day finish to this Southern classic. Also located at 11901 Grand Commons Ave., Fairfax, 571-522-6300.


text:
Q: org.mockito.exceptions.base.MockitoException: Field 'controller' annotated with @InjectMocks is null
it's my controller method

@RequestMapping(value = "/user", method = RequestMethod.POST, consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE, headers = "Accept=application/json")
    public @ResponseBody ResponseMessage getUser(@RequestBody AvailableUser uuid) {
                return manager.available(uuid);
    }

it's my testcontroller

RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = { "classpath*:WEB-INF/spring/appServlet/servlet-context.xml" })

public class TestController {
    public static final MediaType APPLICATION_JSON_UTF8 = new MediaType(MediaType.APPLICATION_JSON.getType(),
            MediaType.APPLICATION_JSON.getSubtype(), Charset.forName("utf8"));

    public TestController() {

    }

    @Mock
    private static Manager manager;
    @InjectMocks
    private Controller controller;
    private RMessage msg;
    private MockMvc mockMvc;
    final ObjectMapper mapper = new ObjectMapper();
    @Before
    public void setup() {
        MockitoAnnotations.initMocks(this);
        this.mockMvc = MockMvcBuilders.standaloneSetup(controller).build();
    }

     @Test
     public void testgetUser() throws Exception
     {

         AvailableUser availableUser=new AvailableUser();
         List<String> lst =new ArrayList<String>();
         lst.add("test1");
         lst.add("test2");
         availableUser.setUuId(lst);
         this.mockMvc.perform(post("/user").contentType(MediaType.APPLICATION_JSON).accept(MediaType.APPLICATION_JSON).content(mapper.writeValueAsString(availableUser)))
        .andExpect(status().isOk());
         when(manager.available(availableUser)).thenReturn(msg);
     }
    }

i got error on the @InjectMocks controller is null.
    it give me hint for that:

class SomeTest {
      @InjectMocks private Foo foo = new Foo();

      @Before public void setUp() {
         MockitoAnnotations.initMock(this);
}}

but i have do that.

 @Before
      public void setup() {
          MockitoAnnotations.initMocks(this);
          this.mockMvc = MockMvcBuilders.standaloneSetup(controller).build();
      }

i got error in console:
  18:16:20,004 DEBUG CacheAwareContextLoaderDelegate:93 - Storing ApplicationContext in cache under key [[MergedContextConfiguration@6483f5ae testClass = TestSurfboardController, locations = '{classpath*:WEB-INF/spring/appServlet/servlet-context.xml}', classes = '{}', contextInitializerClasses = '[]', activeProfiles = '{}', contextLoader = 'org.springframework.test.context.support.DelegatingSmartContextLoader', parent = [null]]].
  18:16:20,106 DEBUG DirtiesContextTestExecutionListener:94 - After test method: context [DefaultTestContext@5fcd892a testClass = TestSurfboardController, testInstance = com.verizon.surfboard.TestSurfboardController@8b87145, testMethod = testgetUser@TestSurfboardController, testException = org.mockito.exceptions.base.MockitoException: Field 'surfboardController' annotated with @InjectMocks is null.

i am properly apply the @InjectMock on the controller after that i
  have done  MockitoAnnotations.initMocks(this);

A: You have to initialize your controller first.
@InjectMocks
private Controller controller = new Controller();

Neither @InjectMocks nor MockMvcBuilders.standaloneSetup will not do it for you.
MockMvcBuilders.standaloneSetup is will throw NPE if you are going to pass null value to it.


text:
The other new normal
by John Whalley, strategic director at Use.Space and head of branding at Seventy7
So much of the talk over recent weeks and months has been about where we sit in the future, literally. #WFH has signed off so many articles, posts and comments about working from home, and the virtues of the Zoom call vs the socially distanced physical meeting debate continues.
It seems the definition of 'The New Normal' has become almost entirely dependent upon physical logistics and levels of tech savvy. But surely this is simply a question of people taking responsibility for reorganising themselves, and allocating what time they need to spend where, in order to be at their most effective. This 'New Normal' could actually just be defined as 'giving people more responsibility'.
The far bigger question is 'The Other New Normal', the one that involves broader behavioural change that can reshape our approach to business and help us move forward together.
Covid-19 has forced us (and continues to force us) to reappraise many things. Response to the pandemic has seen a massive uplift in community spirit, in people helping each other, and in businesses stepping into fresh and different spaces in order to make a difference. The crisis has reawakened many of humanities best qualities.
As we endeavour to 'build back better', collaboration, networks, knowledge sharing, support, purpose and problem-solving are far more important reference points than whether people work from home or not. Success will be driven by our collective behaviour, not by where we choose to sit.
Moving forward together means building meaningful and productive networks, ones where we can share knowledge, form partnerships, encourage collaboration and initiate co-creation. It also requires us to treat collaboration as an opportunity to do more and to do better, rather than simply a way to address gaps in our skillset.
Our audiences are changing too and investing time in understanding their wants and needs, and listening to their expectations, is now more important than ever before. People are having much more of a say in the brands and businesses they choose to connect with, and recent news has only served to highlight just how quickly a business can lose the hearts and minds of consumers and society in general, if they choose to ignore what is important to people.
The Deloitte Insights 2020 Global Marketing Trends Report opens with the importance of human connection and 'keeping the human front and centre', and goes on to say that 'Putting the human at the centre of our trends exploration can help brands forge their own path to making an impact that matters.'
As the economy begins its recovery, we have an opportunity to make real and positive change. For every environmental problem we create there are problem-solvers out there looking for new and innovative ways to fix the issues, and to do things better. We must support these problem-solvers, choose to partner with them wherever possible, and by doing so help build a more sustainable future for everyone. The problem-solvers themselves must share their solutions too.
A recent McKinsey Report on 'The State of Fashion 2020' states that 'Looking forward, we see more research into sustainable materials and technologies, as well as the circular economy. This should lead to a move beyond 2019's focus on transparency toward real commitment. That's great news for consumers and for companies that can make sustainability real.'
Before Covid-19 changed the world, brands and businesses were already recognising 'The Power of Purpose' and its ability to directly affect far more than the P&L. The Deloitte 2020 Global Marketing Trends Report also states that for businesses now 'purpose is everything' and that 'companies that lead with purpose and build around it can achieve continued loyalty, consistency and relevance in the lives of consumers'.
Finally, it falls to all of us to work with and encourage the new talent coming through, supporting them, giving them voice, and providing them with the opportunity to bring a fresh perspective.
Actions speak louder than words, and in August we plan to put these behaviours into action ourselves at Use.Space, our coworking space founded by David Walter here in Manchester. By launching three new pillars of the business, we will provide a hub for the sharing of sustainable solutions, a platform for learning and development, and a network of mentoring and business support.
Turning a negative situation into a positive one is never easy, but we have an opportunity to do just that right now, and we must not miss it.
MPA admin2020-07-30T21:40:16+00:00August 10th, 2020|Blog|


text:
Kramgoa låtar 1999 was released in 1999 as CD and cassette tape. It is a Vikingarna studio album.

Track listing
Våran lilla hemlighet
En slant i fontänen
Still
I mina drömmar
Sjömannen & stjärnan
Vi ska gå hand i hand (Dunja, du)
Nummer ett
Ditt första steg
Kom med mej
Sänd mej ett minne av vår kärlek
Wear My Ring around Your Neck
Ett brev betyder så mycket
Om jag faller faller jag för dig
Sången till dej
Vindar från nordväst (Kuling fra nordvest) (duet Christer Sjögren-Monia Sjöström)

Contributors
Vikingarna
Peter Ljung - keyboard
Janne Lindgren - guitar
Kungliga hovkapellet - strings

Charts

Certifications

References

1999 albums
Vikingarna (band) albums
Swedish-language albums

redpajama_set_name: RedPajamaWikipedia


text:
It's wrong to have soldiers on our streets
Operation Temperer is a rash and unwise move.
Topics Politics
The Joint Terrorism Analysis Centre (JTAC) has decided that, following the attack in Manchester on Monday, Britain's terror threat level should be increased from severe to critical. In response, Theresa May has launched Operation Temperer, which will involve deploying soldiers around the country.
'[A]rmed police officers responsible for duties such as guarding key sites will be replaced by members of the armed forces, which will allow the police to significantly increase the number of armed officers on patrol in key locations', May said. She says Operation Temperer is a 'proportionate and sensible response' to the terror threat.
May says she doesn't want the public to feel 'unduly alarmed'. But her move may well cause alarm. It is a serious, very unusual and very worrying development. Operation Temperer was a secret plan drawn up in January 2015, following the Paris attacks. Then PM David Cameron refused to enact it, because he was worried that deploying military personnel would cause public concern. Aside from Tony Blair's deployment of 450 troops to Heathrow Airport in 2003, Britain hasn't had a military deployment on its streets since the police strikes of 1919 (and of course during the conflict in Northern Ireland).
So May is doing something drastic and extreme. And it is a highly questionable action, too. Rather than being a clear, practical measure against possible violence, the flooding of Britain with soldiers seems to be more about giving an impression of strength. Terrorist attacks are not military threats. A 22-year-old letting off a suicide bomb is not a traditional act of war that can be effectively countered by troops. And yet Operation Temperer effectively turns Britain into a war zone, or at least a militarised zone.
It is likely to make us feel less secure. Seeing armed soldiers on the streets is pretty scary. May is changing the nature of our society in response to terrorism, which is always a mistake. Rather than celebrating genuine defiance in response to Manchester, we are doing something historically abnormal and rash: transforming public life itself by sending soldiers among the people.
Such heightened military engagement in everyday life is wrong. When Blair deployed troops to Heathrow, military chiefs warned him that, 'Once soldiers are deployed, it is difficult to justify pulling them back'. That is, this is a serious step with potentially huge repercussions for the role of the military and the nature of British society. May's decision to deploy 5,000 troops represents a shift towards a more authoritarian era.
What happened in Manchester on Monday night was a despicable assault on human beings, and on our values and our society. But to respond to the attack by taking measures that likewise undermine our values and our society — albeit in a far less violent fashion — is a mistake.
If we allow ourselves to become a nation under armed guard, then we let the bastards win. In Britain, we believe people should be free to go to pop concerts and have fun, and that society should be as open and liberal as possible. The terrorists disagree with us. By enacting Operation Temperer, May risks boosting the terrorist outlook by weakening our everyday sense of liberty.
Ella Whelan is assistant editor at spiked. Follow her on Twitter: @Ella_M_Whelan
Tags Military


Money in the Garage: Trash picking for fun and profit.
Not all your inventory has to come from daily trips to the thrift store and yard sales. I have found numerous items to sell sitting right out at the curb, left for trash. Don't knock it, once I even found a fresh cut Christmas tree with a "free" sign on it. No, I didn't sell it on Ebay, I am not that wackie! The curb side find became our second tree and was displayed in our family room. We always like to put up a smaller tree in the family room, and I figured my find saved me about $35 that year!
But the mother of all freebies for me started one glorious day when I pulled into in my driveway. I looked over to my neighbor's house and my heart rate began to race; there sitting at the curb was a gleaming GE electric oven. I laughed in disbelief...I had some history with this behemoth. The previous owner of this oven had once asked me to help her poor husband schlep it down to her basement. My "Yuppie" neighbor had tricked out her kitchen with new marble and designer appliances. She then had a grand scheme to use the old oven strictly for occasional holiday cooking. But unfortunately for my old neighbor, her corporate job was eliminated and she moved away leaving the "back-up" oven to languish in the basement for the new owner to contend with.
Lucky for me, my brother-in-law was with me when I eyeballed this beauty from across the front yard...a curbside gift from my new neighbor! We quickly went into full alert, hoisting the sparkly clean oven onto my hand truck and wheeled it into my garage. I shut my garage door quickly, not wanting my new neighbor to see I was about to turn a quick profit on his cast-offs.
The oven was a perfect candidate for Craigslist. Since I knew the history of the oven I described how "Mrs. Clean" had owned it and that it was in "like-new" condition. I sold it quickly, thanks to my description and multiple pictures. This curbside moneymaker earned me a fast $125... and it was just sitting out for trash no less! As I was counting my money, I gleefully remembered how I cursed the thing when I carried it down my neighbor's basement. Thanks old neighbor, wherever you are!