If a player gets a 2 match suspension and the referee fails to observe that this is the case until half time and his team uses him during the suspension period what penalty do the rules allow for in this case?
Different competitions have different suspension rules.
However, in most major competitions, it is not the job of the referee to check for eligibility of the players in a team's lineup. That job is given to an official provided by the competition organizers. This official shall check that every player mentioned in the team list (including substitutes) is eligible as per the competition rules.
If even this official does not spot that a suspended player has been selected, the match can either be handed to the opposing team by forfeit, or be replayed, again depending on competition rules or decision made by the organizers of the competition.
For example, in the third qualifying round for the 2014/15 UEFA Champions League, Scottish club Celtic should have lost 6-1 on aggregate to Polish club Legia Warsaw. After losing the away game 4-1, Celtic then lost 2-0 at home. However, it transpired that Legia had used a suspended player as a substitute towards the end of the second leg. Celtic were consequently awarded a 3-0 victory and went through on away goals after the aggregate score was tied at 4-4.
The opposing team can ask to replay the match or the victory 3-0 by forfeit.
e.g. match results assigned by forfeit:
Here from the UEFA Disciplinary Regulations
Article 21 - Forfeit
3 A match may be declared forfeit if a player who is ineligible under the regulations of the competition concerned participates in the match...
4 The consequences of a match being declared forfeit are as follows: a) the team forfeiting the match is deemed to have lost 3-0 (5-0 in futsal competitions), unless the actual result is less favourable to the member association or club at fault..
According to the Brazilian Code for Sports (CBJD, link in Portuguese), rule 214, the team that used the suspended player is punished with the lost of any points obtained in the specific game, additionally the loss of three points in the competition and a fee between R$100.00 (~U$33.00) and R$100.000,00 (~U$33,333).
Note that the other team is not awarded with a win, the result is maintained, ie if the offending team won the match, it loses the three points of that game, plus other three points; but the adversary don't get any additional point. If the offending team lost the game, it still subjected to lose three points in the competition. If the nature of the competition doesn't allow the loss of three points, eg it is a single elimination game, the team is excluded of the competition.
One famous case occurred in 2013 when Portuguesa finished just above the relegation zone but in the last game used one suspended player in the last 15 minutes of the match. The club lost the four points - one awarded for the draw in that fatal game plus other three points - and was relegated to 2nd division.
The difference in the fee is to accommodate the huge difference between 1st national division clubs and very small clubs that play only in regional leagues.
As you could see, the Brazilian regulation is different of the one used by UEFA as the other team is not awarded with a 3-0 win. The rule is defined and enforced by the competition organizer, not referees in the field.
If a suspended player is used, then the team might risk losing the points for that particular match. The match would be counted as a 3-0 victory for the other team.
This happened very recently with Bolivia in the CONMEBOL qualifiers for the 2018 World Cup. Chile and Peru got the points they had lost against Bolivia since the latter team had used a suspended player.
Yeah, that happened once to our country. A player was given a red card in the previous match and in the next one, nobody ever noticed it but he was playing.
The referee didn't notice until he made a corner kick that resulted to a goal so Even though we were leading, we lost 3-0.