Bruce Weber might be at Kansas State forever the way things are going.

The basketball coach signed a two-year contract extension Friday that provides a bump in salary and could keep him with the Wildcats through the 2022-23 season, a nice reward after leading the school to a 25-win season and an appearance in the Elite Eight this past March.

It's also a nice reward considering Weber was thought to be on the hot seat a couple of years ago, before landing a new two-year contract last fall that provided some measure of comfort.

"I've said many time that the support that our players and coaches receive is some of the best in the country," Weber said in a statement. "We're proud of what we've been able to accomplish these last six years, including last season's special run, and this vote of confidence gives the staff and I everything we need to continue to build this program in the right way."

The extension turns Weber's contract into a five-year deal with a salary of $2.5 million this season, and an additional $100,000 for each remaining season. That means Weber will earn $2.9 million if he makes it to the final year of the contract.

The new deal also includes an increase in Weber's buyout. The school would owe him $2.5 million if he's fired before April 30, 2019, with an additional $100,000 the following year. The buyout would drop to $2 million in 2021, $1 million the next year and $500,000 before the final year.

He also will continue to receive the same benefits that were available in his old deal, which includes performance bonuses that could pay out up to 32 percent of his year salary.

He earned 20 percent of his salary in bonuses for reaching the Elite Eight last season.

"We are very fortunate to have not only such an outstanding basketball coach but also a man in Coach Weber who conducts his program with integrity and class and is widely respected across the nation," Kansas State athletic director Gene Taylor said. "Certainly last season was one of the most memorable in our program's history and we're excited for next season and the years ahead."

The Wildcats were picked to finish near the bottom of the Big 12, yet they managed to roll into the NCAA Tournament with plenty of momentum. They wound up knocking off Creighton, upstart UMBC and Kentucky on the way to the Elite Eight, where they fell to Loyola-Chicago just shy of the Final Four.

Perhaps most importantly, every starter and key bench piece is returning this season. Throw in a recruiting class that adds some size and depth and the Wildcats are poised to begin the season firmly in the Top 25, and could challenge Kansas for the Big 12 title next season.

Weber is 125-80 with four NCAA Tournament appearances in six seasons. His win total is the fourth-most in school history, and the most since Jack Hartman retired as the wins leader in 1986.

He is also the fifth Kansas State coach to reach the NCAA Tournament at least four times, and his four 20-win seasons are surpassed by only three other coaches in school history.

"I couldn't be more appreciative of the commitment from President (Richard) Myers and Gene," he said. "We can't wait to get back in the gym and start working with the players again."