Is "Assistant Professor Position (Tenure Track) for a female Researcher" illegal in Austria? Not so long ago an Austrian institution posted a job ad titled "Assistant Professor Position (Tenure Track) for a female Researcher". The description says further


  As part of a special measure towards increasing female employment in scientific positions and promoting young researchers, the Faculty of [censored department] at the [censored institution name] invites applications for an Assistant Professor position (tenure track) for women expected to begin on May 2, 2018.


My understanding is that it is unlawful to ask for a particular gender in a job ad unless the gender is strictly necessary to perform the job duties. For academic tasks, the gender of the researcher is irrelevant. Does the institution run into legal issues with this ad? Could someone legally generate profit from such an ad by suing the institution (or the goverment behind it) for discrimination? Have such attempts been already undertaken in academia? (Outside academia, we see successful lawsuits at least in Germany.)

An aside: Hey, we all agree that in some fields there is a widespread opinion that they would profit from hiring people of the underrepresented gender; we also agree that gender issues exist before hiring, during hiring, and after hiring: they are way too numerous to discuss here. (An example: I see women underrepresented both in my research field and as sewer machine drivers. Why on earth is the politics caring about the first category but not about the second; after all, in an average town, there are way more sewer cars than academic research positions. Another example: my prior boss was an excellent first-class female researcher, but she never ever hired women herself. I could continue with the list ...) So, let us cut short and speak only about the legal and financial part of the particular situation rather than anything else. Let us not discuss whether the job ad and the institution should be condemned or praised or anything of the kind.
In brief,  the job ad in question seems perfectly in line with an official document of the institution, the Career Advancement Plan for Women (see below). If there is any issue it would have to be with this plan, not just the particular job ad, which seems more unlikely.

According to Austrian law it can be legal to put measures into place with the intent of reducing existing inequalities, even when in isolation they would be discrimination. In that sense the understanding of the general principles expressed in the question is correct, except that there is an explicit exception to them if the intent is to reduce existing inequalities.
The most relevant law here is the Bundesgesetz über die Gleichbehandlung [something like 'Federal law for equal treatment'].
It mostly details the understanding recounted in the question, but it also has a paragraph that allows for exceptions of the form mentioned above.

Positive Maßnahmen
§ 8. Die in Gesetzen, in Verordnungen, in Instrumenten der kollektiven Rechtsgestaltung oder in generellen mehrere Arbeitnehmer/innen umfassende Verfügungen des/der Arbeitgebers/Arbeitgeberin getroffenen Maßnahmen zur Förderung der Gleichstellung von Frauen und Männern, insbesondere durch Beseitigung tatsächlich bestehender Ungleichheiten im Sinne des Art. 7 Abs. 2 B-VG, gelten nicht als Diskriminierungen im Sinne dieses Gesetzes. Dies gilt auch für Maßnahmen zur Förderung der Gleichstellung von Frauen und Männern in den in § 4 genannten Bereichen. Der Bund kann für besondere Aufwendungen, die Arbeitgeber/inne/n bei der Durchführung solcher Maßnahmen entstehen, Förderungen gewähren.

Somewhat improved Google Translate's translation:

Positive action
§ 8. The measures taken in laws, regulations, collective legal instruments or in general multi-employee dispositions of the employer to promote equality between women and men, in particular by eliminating existing inequalities within the meaning of Art Art. 7 para. 2 B-VG are not considered to be discrimination within the meaning of this Act. This also applies to measures to promote equality between women and men in the areas mentioned in § 4. The Federal Government may grant subsidies for special expenses that employers incur in carrying out such measures.

The title is &quot;positive measures&quot; and then it roughly says that measures whose intent it is to level existing inequalities are not consider as discrimination and federal government might even fund them.
Now, this does not simply authorize everybody to do whatever they think might be appropriate. But, it admits the general principle, and further laws and regulations can build on it.
Let me now jump from the general to the concrete.
The job ad in question seems to be in line, and likely even motivated, by an official document of the institution in question (or if it is not the institution in question than it is a comparable one). Thus, if something should not be legal it would be this plan. The above mentioned §8 should be applicable to this document.
This document, called Frauenförderungsplan [Career Advancement Plan for Women] contains among other things §6(3) (quoting the English version):

To increase the proportion of women among professors and among young scientists, special measures
shall be taken, for example establishing tenure-track positions and professorships for women.

That the institution has such a Career Advancement Plan for Women is motivated by, indeed prescribed by, the Austrian law that governs the organization of universities [Universitätsgesetz 2002 – UG], specifically §20b.
Also of relevance §41:

§ 41. Alle Organe der Universität haben darauf hinzuwirken, dass in allen universitären Arbeitsbereichen ein ausgewogenes Zahlenverhältnis zwischen den an der Universität tätigen Frauen und Männern erreicht wird. Die Erreichung dieses Ziels ist durch geeignete Maßnahmen, insbesondere durch die Erlassung und Umsetzung eines Frauenförderungsplans, anzustreben.

Saying roughly (my translation) &quot;All parts of the university must work towards achieving equal numbers of women and man employed, for all types of employment. This goal shall be achieved by putting appropriate measures into place, in particular by adopting and implementing a career advancement plan for women.
The respective plans for this and other Austrian universities can also be found on a site of the Austrian government.
Maybe noteworthy, I did not find that explicit suggestions in some others which I looked at though; I did not look at all and not very carefully either.
Another relevant law would be the Bundes-Gleichbehandlungsgesetz – B-GlBG, especially §11. Specifically § 11b.(1) not only authorizes but prescribes the practice described in the answer of rexkogitans for areas in which women are underrepresented. (While universities, I think, are not directly in any case not completely covered by this law, since it is about employment by the Austrian state, which is not anymore the way people are employed at Austrian universities, except for some existing old contracts, explicit reference is made to this regulation in the above mention document as some king of inspiration.)
Further legal explications can be found in the Career Advancement Plan for Women quoted above.
To sum up, the job ad in question seems perfectly in line with an official document of the institution, the Career Advancement Plan for Women. If there is any issue it would have to be with this plan, not the particular job ad.
Yet this plan makes detailed reference to various laws and alike (roughly and clumsily recounted above); certainly people with legal expertise were involved in the creation of that document.
Now, in principle, it is still possible that there is some legal problem with this plan or opposing legal opinions of what is or is not legal, but if there is one it should be rather subtle.
Indeed, there are earlier precedence for this practice. In 2010 an Austrian newspaper reported about some assistant professor positions advertised for women only at another Austrian university. A representative of the university is quoted:

Das stelle auch keine unzulässige Diskriminierung dar, sagt Manfred Rathmoser, Sprecher der Uni Linz. So seien laut EU-Recht „spezifische Vergünstigungen für ein Geschlecht zulässig“, wenn diese zum Ausgleich von Benachteiligungen dienen. Und Frauen seien in der Wissenschaft unterrepräsentiert.

My rough translation:

This is no inadmissible discrimination, says Manfred Rathmoser, speaker of the University of Linz. For, according to EU law &quot;specific advantages for one gender are admissible&quot; if those serve to even out existing disadvantages. And women in research are underrepresented.

However it continues:

So einfach sei die Sache nicht, betont jedoch Bernd-Christian Funk, Experte für öffentliches Recht an der Uni Wien. Funk studierte für die „Presse“ die Stellenausschreibung genau. Sein Schluss: „Ich halte sie gelinde gesagt für rechtlich problematisch“, so Funk.

My translation:

The situation is not so simple, emphasizes Bernd-Christian Funk, expert for public law the the University of Vienna. Funk studied the job advertisement for &quot;Presse&quot; [the name of the newspaper]. His conclusion: &quot;I consider them, put mildly, as legally problematic,&quot; said Funk.

It then continues to say that while things like preferential treatment in cases of equal qualification are alright this goes to far and is against European and Austrian legal norms. The advice to men that feel discriminated was to apply and to then go to court.
If you or somebody else wants to pursue this matter seriously it may be an option to contact him (Funk) and inquirer what he thinks about this now, and  the relevant paragraph of the &quot;Frauenförderungsplan&quot; of the TU Wien. It seems he is still active, though at a different institution, and his contact details are easy to find. You could also contact the relevant institution.
Conclusion: The job ad seems to be covered by official documents and policies of the university, which in some detail argue how they tie in with Austrian law. This notwithstanding there appear to be opposing legal opinions, too.